|
|
вернуться в форумMy AC int main() { int n; scanf("%d", &n); d[0] = 5; d[1] = 20; d[2] = 12; d[3] = 2; d[4] = 1; d[5] = 4; d[6] = 6; d[7] = 1; d[8] = 4; d[9] = 4; d[10] = 1; d[11] = 0; printf("%d", d[n]); return 0; } Re: My AC Yeah, I solved it without looking into discussions. int n, p[]={5,20,12,2,1,4,6,1,4,4,1,0}; int main() { cin >> n; cout << p[n]; return 0; } P.S. this problem is EVIL! (o_O) Re: My AC Hey, let others also solve it, don't just post here the solution! Re: My AC Послано hatred 30 дек 2011 00:24 Why Sasha is 2, he didnt visit 1 contest Re: My AC Thank you for your solution, I didn't want to read these megabytes of letters by myself. Re: My AC + + + - - - - - - - - - + + + - - - - - - - - - + + + - - - - - - - - - + + + - - - - - - - - - + + + - - - - - - - - - // Dissolution of Alarm - + + - - - - - - - - - - + + + - - - - - - - - - + + - + - - - - - - - - + + - - + - - - - - - - + - - - + - - - - - - // Next year - + + - - - + - - - - - - + + - - - + - - - - - - + + - - - + - - - - - - + - - - - + + - - - - // Lesha gone - - - - - + + - - - - - - + - - - + + - - - - - // Nikita & Fedya gone - + - - - - - - + + - - - + - - - - - - + + - - - + - - - - - - + + - - - + - - - - - - + + - - // One more dissolution of team - + - - - - - - - - + + // UNCOUNT - + - + - - - - - - + - |
|
|