#include<iostream> #include<algorithm> using namespace std; int main() { int n; cin>>n; int x=1; n--; while(n--) { x=(x+1)*2; } cin>>x; return 0; } return 0; } /* Main.cc:21:3: error: expected unqualified-id before 'return' return 0; ^~~~~~ Main.cc:22:5: error: expected declaration before '}' token } ^ */ |
Double click to view unformatted code.