记录详情

Compile Error

/in/foo.cc:12:31: error: 'm' has not been declared
     void FindMinCount(int a[],m);
                               ^
/in/foo.cc:22:36: error: 'm' has not been declared
 void SeqList::FindMinCount(int a[],m){
                                    ^
/in/foo.cc: In member function 'void SeqList::FindMinCount(int*, int)':
/in/foo.cc:26:12: error: 'm' was not declared in this scope
  for(i=0;i<m;i++)
            ^
/in/foo.cc:29:13: error: overloaded function with no contextual type information
      max=a[i];
             ^
/in/foo.cc:34:15: error: 'm' was not declared in this scope
     for(i=0;i<m;i++){
               ^
/in/foo.cc:25:6: warning: unused variable 'n' [-Wunused-variable]
  int n=0;
      ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:58:29: error: 'm' has not been declared
  void FindMinCount(int a[0],m);
                             ^
/in/foo.cc:59:10: error: conflicting declaration 'SeqList a'
  SeqList a;
          ^
/in/foo.cc:44:8: note: previous declaration as 'int a [10000]'
    int a[10000];
        ^
/in/foo.cc:60:5: error: request for member 'FindMinCount' in 'a', which is of non-class type 'int [10000]'
   a.FindMinCount(a,n1);
     ^~~~~~~~~~~~
/in/foo.cc:61:10: error: conflicting declaration 'SeqList b'
  SeqList b;
          ^
/in/foo.cc:45:8: note: previous declaration as 'int b [10000]'
    int b[10000];
        ^
/in/foo.cc:62:5: error: request for member 'FindMinCount' in 'b', which is of non-class type 'int [10000]'
   b.FindMinCount(b,n2);
     ^~~~~~~~~~~~

信息

递交者
类型
递交
题目
A9-5 数组中最小值的个数
比赛
中北数据结构课程赛事二:顺序表类的操作
语言
C++
递交时间
2019-03-10 21:29:57
评测时间
2019-03-10 21:29:57
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes