/ Vijos /

记录详情

Compile Error

foo.c: In function 'main':
foo.c:13:2: error: unknown type name 'item'
  item items[105];
  ^
foo.c:16:31: error: request for member 't' in something not a structure or union
         scanf("%d%d",&items[i].t,&items[i].v);
                               ^
foo.c:16:43: error: request for member 'v' in something not a structure or union
         scanf("%d%d",&items[i].t,&items[i].v);
                                           ^
foo.c:21:17: error: request for member 't' in something not a structure or union
    if(j<items[i].t||i==0)
                 ^
foo.c:26:43: error: request for member 't' in something not a structure or union
    b[i][j]=max(b[i-1][j],b[i-1][j-items[i].t]+items[i].v);
                                           ^
foo.c:26:55: error: request for member 'v' in something not a structure or union
    b[i][j]=max(b[i-1][j],b[i-1][j-items[i].t]+items[i].v);
                                                       ^
foo.c:13:7: warning: variable 'items' set but not used [-Wunused-but-set-variable]
  item items[105];
       ^

信息

递交者
类型
递交
题目
P1104 采药
语言
C
递交时间
2016-11-02 22:20:19
评测时间
2016-11-02 22:20:20
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes