      PROGRAM A
      IMPLICIT NONE
      INTEGER :: input(3),ans
      INTEGER :: index
      
      
      read'(I1,I1,I1)', input(1),input(2),input(3)
      
      ans = 0
      DO index = 1,3
        IF(input(index)==1)THEN
        ans = ans + 1
        END IF
      END DO
      
      print'(I0)',ans
      
      END PROGRAM