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
596828 Nguyễn Hoàng Hảo Số chia hết C/C++ Lỗi biên dịch (CE) 0 MS 0 KB 1233 2024-10-31 20:29:52

Lỗi biên dịch:

Main.cc: In function ‘int BCNN(int, int)’:
Main.cc:14:17: error: ‘ucln’ was not declared in this scope
   14 |     return (a / ucln(a, b)) * b;
      |                 ^~~~
Main.cc: In function ‘int TinhBCNN(int*, int)’:
Main.cc:20:12: error: ‘bcnn’ was not declared in this scope
   20 |         kq=bcnn(kq, tapB[i]);
      |            ^~~~
Main.cc: In function ‘int TinhUCLN(int*, int)’:
Main.cc:28:12: error: ‘ucln’ was not declared in this scope
   28 |         kq=ucln(kq, tapA[i]);
      |            ^~~~
Main.cc: In function ‘int main()’:
Main.cc:48:10: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   48 |     scanf("%d %d", &N, &M);
      |     ~~~~~^~~~~~~~~~~~~~~~~
Main.cc:52:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   52 |         scanf("%d", &tapA[i]);
      |         ~~~~~^~~~~~~~~~~~~~~~
Main.cc:55:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   55 |         scanf("%d", &tapB[i]);
      |         ~~~~~^~~~~~~~~~~~~~~~