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
98364 Hoan và An GHÉP ĐOẠN MÃ C/C++ Lỗi biên dịch (CE) 0 MS 0 KB 521 2023-05-26 14:14:54

Lỗi biên dịch:

Main.cc: In function ‘bool xetdl(long long int, long long int*)’:
Main.cc:9:11: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
     if( m < x[ji]) return false;
         ~~^~~~~~~
Main.cc: In function ‘int main()’:
Main.cc:29:14: error: invalid conversion from ‘long long unsigned int*’ to ‘long long int*’ [-fpermissive]
  if(xetdl(n,x))
              ^
Main.cc:3:6: note:   initializing argument 2 of ‘bool xetdl(long long int, long long int*)’
 bool xetdl(long long n,long long x[]){
      ^~~~~
Main.cc:22:7: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
  scanf("%lld",&n);
  ~~~~~^~~~~~~~~~~
Main.cc:26:8: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
   scanf("%lld",&x[i]);
   ~~~~~^~~~~~~~~~~~~~