program sample1
implicit none

integer a,b
read(*,*) a
b=0
If(a/100.0>=1.0) then
   b=b+1
   a=a-100
end if   
If(a/10.0>=1.0) then
   b=b+1
   a=a-10
end if
If(a>=1) then
    b=b+1
end if
write(*,*) b

stop
end program sample1


