#include <bits/stdc++.h>
int main(void) {
  int s1, s2, s3, count = 0;
  scanf("%d%d%d", &s1, &s2, &s3);
  if (s1 == 1) count++;
  if (s2 == 1) count++;
  if (s3 == 1) count++;
  printf("%d", count);
  return 0;
}
