Elevator其实是一道水题,思路也很简单,但不知道怎么也不能AC,后来看了别人的再比较自己的以后找到错误. 在判断奇偶数之后的语句时,我用了if() else if(),这是不能AC的原因,这种条件判断的话,会忽略连续输入两个相等数的情况. #include <iostream> using namespace std; int e[105]; int main() { int n; while(cin>>n&&n!=0) { int time_0 = 0;…
A Number Puzzle Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 938 Accepted Submission(s): 276 Problem Description Lele 最近上课的时候都很无聊,所以他发明了一个数字游戏来打发时间.这个游戏是这样的,首先,他拿出几张纸片,分别写上0到9之间的任意数字(可重复写…
HDU 5418 Victor and World Time Limit:2000MS Memory Limit:131072KB 64bit IO Format:%I64d & %I64u After trying hard for many years, Victor has finally received a pilot license. To have a celebration, he intends to buy himself an airplane and fl…
HDU 5285 wyh2000 and pupil Time Limit:1500MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u Description Young theoretical computer scientist wyh2000 is teaching his pupils. Wyh2000 has n pupils.Id of them are from to .In order to inc…