fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3. int main()
  4. {int a,b=0,i=1,j;
  5. cin>>a;
  6. pantha:
  7. j=a/i;
  8. if(j!=0){
  9. b=b+1;
  10. i=i*10;
  11. goto pantha;
  12. }else {goto end;}
  13. end:
  14. cout<<b;
  15. return 0;
  16. }
Success #stdin #stdout 0s 16064KB
stdin
4387654329
stdout
31