nishanth.molleti9's blog

By nishanth.molleti9, history, 4 months ago, In English,

I have been trying to solve this problem lately and I find that there is something wrong with it . Can someone help me solving it. https://codeforces.com/contest/656/problem/A

The code i used to solve it is attached below (in C language)

include<stdio.h>

include<math.h>

main() { double a,c; scanf("%lf",&a); if(0<=a<=35){ c=pow(2, a); printf("%.0lf",c); } }

Please help me out :)

 
 
 
 
  • Vote: I like it
  • -16
  • Vote: I do not like it

»
4 months ago, # |
Rev. 2   Vote: I like it 0 Vote: I do not like it

this solution is wrong, the answer isn't the sequence of powers of 2