Task: | Ruudukko |
Sender: | hltk |
Submission time: | 2019-05-14 18:59:58 +0300 |
Language: | C++ |
Status: | READY |
Result: | 0 |
group | verdict | score |
---|---|---|
#1 | WRONG ANSWER | 0 |
#2 | WRONG ANSWER | 0 |
#3 | WRONG ANSWER | 0 |
test | verdict | time | group | |
---|---|---|---|---|
#1 | WRONG ANSWER | 0.03 s | 1 | details |
#2 | WRONG ANSWER | 0.03 s | 1 | details |
#3 | WRONG ANSWER | 0.01 s | 1 | details |
#4 | WRONG ANSWER | 0.03 s | 1 | details |
#5 | WRONG ANSWER | 0.02 s | 1 | details |
#6 | WRONG ANSWER | 0.01 s | 2 | details |
#7 | WRONG ANSWER | 0.02 s | 2 | details |
#8 | WRONG ANSWER | 0.02 s | 2 | details |
#9 | WRONG ANSWER | 0.01 s | 2 | details |
#10 | WRONG ANSWER | 0.01 s | 2 | details |
#11 | WRONG ANSWER | 0.02 s | 3 | details |
#12 | WRONG ANSWER | 0.03 s | 3 | details |
#13 | WRONG ANSWER | 0.03 s | 3 | details |
#14 | WRONG ANSWER | 0.02 s | 3 | details |
#15 | WRONG ANSWER | 0.02 s | 3 | details |
Compiler report
input/code.cpp: In function 'void solve()': input/code.cpp:26:30: warning: format '%d' expects argument of type 'int', but argument 2 has type 'long int' [-Wformat=] printf("%d %d %d\n", a, b, c); ^ input/code.cpp:26:30: warning: format '%d' expects argument of type 'int', but argument 3 has type 'long int' [-Wformat=] input/code.cpp:26:30: warning: format '%d' expects argument of type 'int', but argument 4 has type 'long int' [-Wformat=]
Code
#include <bits/stdc++.h> using namespace std; void solve() { long a, b, c, n; cin >> a >> b >> c >> n; if (a > c) swap(a,c); if (b > c) swap(b,c); if (a > b) swap(a,b); for (int i = 1; i <= n; ++i) { if (a + 1 == b && b == c) break; if (a == b && b + 1 == c) break; if (a + 1 == b && b + 1 == c) { if ((n - i + 1) % 2 == 1) { a++; c--; } break; } a ++; c --; if (a > c) swap(a,c); if (b > c) swap(b,c); if (a > b) swap(a,b); } printf("%d %d %d\n", a, b, c); } int main() { int t; cin >> t; while (t--) solve(); }
Test details
Test 1
Group: 1
Verdict: WRONG ANSWER
input |
---|
2 |
correct output |
---|
.................... .################### .################### .################### .################### ... |
user output |
---|
1714478848 2 23326064 1714478848 2 23326064 |
Test 2
Group: 1
Verdict: WRONG ANSWER
input |
---|
5 |
correct output |
---|
.................... .################..# .#################.. .#################.. .##################. ... |
user output |
---|
-1537799680 5 29248880 -1537799680 5 29248880 -1537799680 5 29248880 -1537799680 5 29248880 -1537799680 5 29248880 |
Test 3
Group: 1
Verdict: WRONG ANSWER
input |
---|
7 |
correct output |
---|
.................... .################..# .#################.. .#################.. .##################. ... |
user output |
---|
-2046174464 7 25480560 -2046174464 7 25480560 -2046174464 7 25480560 -2046174464 7 25480560 -2046174464 7 25480560 ... |
Test 4
Group: 1
Verdict: WRONG ANSWER
input |
---|
8 |
correct output |
---|
.................... .################### .################### .################### .################### ... |
user output |
---|
8 32570736 1916097536 8 32570736 1916097536 8 32570736 1916097536 8 32570736 1916097536 8 32570736 1916097536 ... |
Test 5
Group: 1
Verdict: WRONG ANSWER
input |
---|
9 |
correct output |
---|
.................... .################### .################### .################### .################### ... |
user output |
---|
9 24489328 -1223343872 9 24489328 -1223343872 9 24489328 -1223343872 9 24489328 -1223343872 9 24489328 -1223343872 ... |
Test 6
Group: 2
Verdict: WRONG ANSWER
input |
---|
19 |
correct output |
---|
.................... .############..##### .#############..#### .#############...### .##############...## ... |
user output |
---|
19 24735088 1549659392 19 24735088 1549659392 19 24735088 1549659392 19 24735088 1549659392 19 24735088 1549659392 ... |
Test 7
Group: 2
Verdict: WRONG ANSWER
input |
---|
32 |
correct output |
---|
.................... .################### .################### .################### .################### ... |
user output |
---|
240521472 32 20458864 240521472 32 20458864 240521472 32 20458864 240521472 32 20458864 240521472 32 20458864 ... |
Test 8
Group: 2
Verdict: WRONG ANSWER
input |
---|
44 |
correct output |
---|
.................... .################..# .#################.. .#################.. .##################. ... |
user output |
---|
1896646144 44 23002480 1896646144 44 23002480 1896646144 44 23002480 1896646144 44 23002480 1896646144 44 23002480 ... |
Test 9
Group: 2
Verdict: WRONG ANSWER
input |
---|
76 |
correct output |
---|
.................... .########..######..# .#########..######.. .#########...#####.. .##########...#####. ... |
user output |
---|
1770538752 76 20114800 1770538752 76 20114800 1770538752 76 20114800 1770538752 76 20114800 1770538752 76 20114800 ... |
Test 10
Group: 2
Verdict: WRONG ANSWER
input |
---|
93 |
correct output |
---|
.................... .########..##..##..# .#########..##..##.. .#########...#...#.. .##########...#...#. ... |
user output |
---|
93 28335472 -409512448 93 28335472 -409512448 93 28335472 -409512448 93 28335472 -409512448 93 28335472 -409512448 ... |
Test 11
Group: 3
Verdict: WRONG ANSWER
input |
---|
141 |
correct output |
---|
.................... .################..# .#################.. .#################.. .##################. ... |
user output |
---|
141 30207344 1191236864 141 30207344 1191236864 141 30207344 1191236864 141 30207344 1191236864 141 30207344 1191236864 ... |
Test 12
Group: 3
Verdict: WRONG ANSWER
input |
---|
422 |
correct output |
---|
.................... .####..##########..# .#####..##########.. .#####...#########.. .######...#########. ... |
user output |
---|
422 28663152 -935704832 422 28663152 -935704832 422 28663152 -935704832 422 28663152 -935704832 422 28663152 -935704832 ... |
Test 13
Group: 3
Verdict: WRONG ANSWER
input |
---|
671 |
correct output |
---|
.................... .#.##########..##..# ....##########..##.. .#...#########...#.. .##...#########...#. ... |
user output |
---|
671 28224880 7765504 671 28224880 7765504 671 28224880 7765504 671 28224880 7765504 671 28224880 7765504 ... |
Test 14
Group: 3
Verdict: WRONG ANSWER
input |
---|
895 |
correct output |
---|
.................... .#.##..##..##..##..# ....##..##..##..##.. .#...#...#...#...#.. .##...#...#...#...#. ... |
user output |
---|
-635278848 895 23149936 -635278848 895 23149936 -635278848 895 23149936 -635278848 895 23149936 -635278848 895 23149936 ... |
Test 15
Group: 3
Verdict: WRONG ANSWER
input |
---|
956 |
correct output |
---|
.................... .#.##..######..##..# ....##..######..##.. .#...#...#####...#.. .##...#...#####...#. ... |
user output |
---|
956 25804144 -484603904 956 25804144 -484603904 956 25804144 -484603904 956 25804144 -484603904 956 25804144 -484603904 ... |