Submission #17168616
Source Code Expand
#include <bits/stdc++.h> int main() { int a, b; scanf("%d%d", &a, &b); printf("%d %d\n", (a + b) / 2, (a - b) / 2); return 0; }
Submission Info
Submission Time | |
---|---|
Task | A - Plus Minus |
User | siyuan |
Language | C++ (GCC 9.2.1) |
Score | 100 |
Code Size | 139 Byte |
Status | AC |
Exec Time | 8 ms |
Memory | 3696 KiB |
Compile Error
./Main.cpp: In function ‘int main()’: ./Main.cpp:5:7: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result] 5 | scanf("%d%d", &a, &b); | ~~~~~^~~~~~~~~~~~~~~~
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 100 / 100 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | s1.txt, s2.txt |
All | 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, s1.txt, s2.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
01.txt | AC | 8 ms | 3620 KiB |
02.txt | AC | 2 ms | 3656 KiB |
03.txt | AC | 2 ms | 3608 KiB |
04.txt | AC | 1 ms | 3624 KiB |
05.txt | AC | 2 ms | 3532 KiB |
06.txt | AC | 3 ms | 3624 KiB |
07.txt | AC | 1 ms | 3668 KiB |
08.txt | AC | 2 ms | 3684 KiB |
09.txt | AC | 2 ms | 3548 KiB |
10.txt | AC | 2 ms | 3696 KiB |
s1.txt | AC | 1 ms | 3620 KiB |
s2.txt | AC | 2 ms | 3532 KiB |