Borderou de evaluare (job #2302305)
| Utilizator | Data | 14 decembrie 2018 09:54:28 | |
|---|---|---|---|
| Problema | Algoritmul Bellman-Ford | Status | done |
| Runda | Arhiva educationala | Compilator | c-64 | Vezi sursa |
| Scor | 0 | ||
Raport evaluator
Eroare de compilare:
main.c:6:5: error: unknown type name 'P'
P *u;
^
main.c:7:2: error: variably modified 'g' at file scope
}g[N],p;
^
main.c:8:8: error: unknown type name 'P'
void A(P *p,int b,int c)
^
main.c:13:19: error: conflicting types for 'p'
int m,n,i,j,k,l,r,p,d[N]={N},e[1500000],a,b,c,v[50001],u[50001];
^
main.c:7:7: note: previous declaration of 'p' was here
}g[N],p;
^
main.c:13:21: error: variably modified 'd' at file scope
int m,n,i,j,k,l,r,p,d[N]={N},e[1500000],a,b,c,v[50001],u[50001];
^
main.c:13:27: error: initializer element is not constant
int m,n,i,j,k,l,r,p,d[N]={N},e[1500000],a,b,c,v[50001],u[50001];
^
main.c:13:27: note: (near initialization for 'd[0]')
main.c: In function 'main':
main.c:17:34: warning: implicit declaration of function 'A' [-Wimplicit-function-declaration]
scanf("%d%d%d",&a,&b,&c),A(g[a],b,c);
^
main.c:19:30: error: incompatible types when assigning to type 'int' from type 'struct P'
for(j=e[l++],v[j]=0,p=g[j];p&&!k;p=p->u)
^
main.c:19:45: error: invalid type argument of '->' (have 'int')
for(j=e[l++],v[j]=0,p=g[j];p&&!k;p=p->u)
^~
main.c:20:19: error: invalid type argument of '->' (have 'int')
if(d[p->x]>d[j]+p->y)
^~
main.c:20:30: error: invalid type argument of '->' (have 'int')
if(d[p->x]>d[j]+p->y)
^~
main.c:22:20: error: invalid type argument of '->' (have 'int')
d[p->x]=d[j]+p->y;
^~
main.c:22:31: error: invalid type argument of '->' (have 'int')
d[p->x]=d[j]+p->y;
^~
main.c:23:24: error: invalid type argument of '->' (have 'int')
if(!v[p->x])
^~
main.c:24:27: error: invalid type argument of '->' (have 'int')
if(u[p->x]>n)
^~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !
