|
|
back to boardCommon BoardAbout compilation. Dear sir/madam, Could you, please, point out what compilers do you use? It's very important. On problem 1054 I received compilation error on the first attempt (#32413), although my VC++6.0 compiler did not find any mistakes. the problem was the following: --- error --- for (long i = 0; i < n; i++) cin >> d[i]; for (i = 1; i < 31; i++) st2[i] = 2*st2[i-1]; << here you said "temp\32413(28) : error C2065: 'i' : undeclared identifier" --- I corrected it ------- long i; for (i = 0; i < n; i++) cin >> d[i]; for (i = 1; i < 31; i++) st2[i] = 2*st2[i-1]; -------------------------- In second case I received Accepted :(. I suppose, the first case was correct too if we say about C++. Please, give some explanations. Thank you in advance, Matvey Kazakov (kazakov@green.ifmo.ru). Re: About compilation. There is an option in cl.exe (though i don't remember it exactly, that disables microsoft extensions and leaves only ANSI C++ limitations. I am not familiar with ANSI C++ standard. But you can look. ) |
|
|