Mã chấm |
Tài khoản |
Bài tập |
Ngôn ngữ lập trình |
Trạng thái |
Thời gian |
Bộ nhớ |
Kích thước |
Thời gian nộp |
467406 |
DT
|
MÁY RÚT TIỀN TỰ ĐỘNG |
C/C++ |
Lỗi biên dịch (CE) |
0 MS
|
0 KB
|
1337 |
2024-05-25 02:06:19 |
Lỗi biên dịch:
Main.cc: In function ‘int drasc(int*, int, int)’:
Main.cc:25:13: error: call of overloaded ‘swap(int&, int&)’ is ambiguous
25 | swap(a[t], a[b]);
| ~~~~^~~~~~~~~~~~
Main.cc:4:6: note: candidate: ‘void swap(int, int)’
4 | void swap(int x,int y);
| ^~~~
Main.cc:10:6: note: candidate: ‘void swap(int&, int&)’
10 | void swap(int &x,int &y){
| ^~~~
Main.cc:29:9: error: call of overloaded ‘swap(int&, int&)’ is ambiguous
29 | swap(a[t], a[r]);
| ~~~~^~~~~~~~~~~~
Main.cc:4:6: note: candidate: ‘void swap(int, int)’
4 | void swap(int x,int y);
| ^~~~
Main.cc:10:6: note: candidate: ‘void swap(int&, int&)’
10 | void swap(int &x,int &y){
| ^~~~
Main.cc: In function ‘int main()’:
Main.cc:46:13: warning: unused variable ‘sum’ [-Wunused-variable]
46 | int sum = 0;
| ^~~
Main.cc:49:13: warning: unused variable ‘count’ [-Wunused-variable]
49 | int count = 0;
| ^~~~~