Mn sửa bài này giúp với ạ mình, mình cần gấp, cảm ơn mn
----- Nội dung dịch tự động từ ảnh -----
D:\thinh\c++\test\demcapdoi.cpp - Dev-C++ 5.8.3
File Edit Search View Project Execute Jools Window Help
Project Classes Debug
(globals)
Compiler (3)
Line Col File
8
13
Line: 11
demcapdoi.cpp
1 #include
#include
using namespace std;
int main()
3
Col: 28
4
5
6
78 (
8
9
10
11
12
13
14 E
15
16
***⠀⠀⠀85555
17
18
t
19
20
21
int n
readint();
int k
readInt ();
map M;
while (n--) M [readInt()]++;
long long rese;
for (pair e: M)
(
D:\thinh\c + + \test\demcapdoi.cpp
21 D:\thinh\c++\test\demcapdoi.cpp
D:\thinh\c++\test\demcapdoi.cpp
30
Sel: 0
int nxe.first;
int fx e.second;
intzke.first;
int fy M [2];
M.erase (2);
if (nx == 2) res+1LLfx (fx - 1) / 2;
else res 1LLfx fy;
cout << res;
return 0;
Resources Compile Log✔✔ Debug Find Results
Message
In function 'int main()':
[Error] 'readint' was not declared in this scope
[Error] range-based for loops are not allowed in C++98 mode
88 = 88
Lines: 26
Length: 507
Close
I
Insert
TDM-GCC 4.8.1 64-bit Release
Done parsing in 0.031 seconds
1
0
X
0 Xem trả lời
87