fork download
  1. int main() {
  2. string s=Stdio.stdin.gets();
  3. int i=strlen(s);
  4. int res=0;
  5. int j=i-1;
  6. while(j>=0){
  7. write("%d\n",s[j]);
  8. if(s[j]==49){
  9. res= res+pow(2,i-j-1);
  10. }
  11. j = j-1;
  12. }
  13. return 0;
  14. }
Success #stdin #stdout 0.05s 10120KB
stdin
0110111010001000101000110111011001101111111110000000001000101110000011110101010111000101000101011110
stdout
48
49
49
49
49
48
49
48
49
48
48
48
49
48
49
48
48
48
49
49
49
48
49
48
49
48
49
48
49
49
49
49
48
48
48
48
48
49
49
49
48
49
48
48
48
49
48
48
48
48
48
48
48
48
48
49
49
49
49
49
49
49
49
49
48
49
49
48
48
49
49
48
49
49
49
48
49
49
48
48
48
49
48
49
48
48
48
49
48
48
48
49
48
49
49
49
48
49
49
48