criyle/codenet-compile-errors huggingface dataset:
Language: C

#include<stdio.h>

int main(void) {
int n,m;
int i,j;
int ans = 0;
int matA[][];
int matB[];

scanf("%d %d", &n, &m);

for(int i = 0; i < n; i++) {
for(int j = 0; j < m; j++) {
scanf("%d", &matA[i][j]);
}
}
for(int j = 0; j < m; j++) {
scanf("%d", &matB[j]);
}

for(int i = 0; i < n; i++) {
for(int j = 0; j < m; j++) {
ans += matAi][j]*matB[j];
}
}
printf("%d", ans);

return (0);
}

Compiler output:
main.c: In function 'main':
main.c:7:5: error: array type has incomplete element type 'int[]'
    7 | int matA[][];
      |     ^~~~
main.c:7:5: note: declaration of 'matA' as multidimensional array must have bounds for all dimensions except the first
main.c:8:5: error: array size missing in 'matB'
    8 | int matB[];
      |     ^~~~
main.c:23:8: error: 'matAi' undeclared (first use in this function); did you mean 'matA'?
   23 | ans += matAi][j]*matB[j];
      |        ^~~~~
      |        matA
main.c:23:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:23:13: error: expected ';' before ']' token
   23 | ans += matAi][j]*matB[j];
      |             ^
      |             ;
main.c:23:13: error: expected statement before ']' token
main.c:23:14: error: expected expression before '[' token
   23 | ans += matAi][j]*matB[j];
      |              ^
Language: C

#include<stdio.h>

int main(void) {
int n,m;
int i,j;
int ans;

scanf("%d %d", &n, &m);
int matA[n][m];
int matB[m];

for(i = 0; i < n; i++) {
for(j = 0; j < m; j++) {
scanf("%d", &matA[i][j]);
}
}
for(j = 0; j < m; j++) {
scanf("%d", &matB[j]);
}

for(i = 0; i < n; i++) {
ans = 0;
for(j = 0; j < m; j++) {
ans += matAi][j]*matB[j];
}
printf("%d\n", ans);
}
printf("%d", ans);

return (0);
}

Compiler output:
main.c: In function 'main':
main.c:24:8: error: 'matAi' undeclared (first use in this function); did you mean 'matA'?
   24 | ans += matAi][j]*matB[j];
      |        ^~~~~
      |        matA
main.c:24:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:24:13: error: expected ';' before ']' token
   24 | ans += matAi][j]*matB[j];
      |             ^
      |             ;
main.c:24:13: error: expected statement before ']' token
main.c:24:14: error: expected expression before '[' token
   24 | ans += matAi][j]*matB[j];
      |              ^
Language: C

int main(void)
{
	int n,m,t,i,j;

	scanf("%d %d",&n,&m);
	
	int a[n][m] ,b[m] ,ans[n];

	for(i=0;i<n;i++)
	{
		for(j = 0;j<m;j++)
		{
			scnaf("%d",&a[i][j]);
		}
	}



	for(i=0;i<m;i++)
	{
		scanf("%d",&b[i]);
	}

	for(i=0;i<n;i++)
	{
		t = 0;
		
		for(j=0;j<m;j++)
		{
			t+=(a[i][j]*b[j]);
			
		}

		ans[i] = t;
		
		}

	for(i=0;i<n;i++)
	{
		printf("%d\n",ans[i]);
	}


	
	return 0;

}

Compiler output:
main.c: In function 'main':
main.c:5:9: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    5 |         scanf("%d %d",&n,&m);
      |         ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | int main(void)
main.c:5:9: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    5 |         scanf("%d %d",&n,&m);
      |         ^~~~~
main.c:5:9: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:13:25: error: implicit declaration of function 'scnaf' [-Wimplicit-function-declaration]
   13 |                         scnaf("%d",&a[i][j]);
      |                         ^~~~~
main.c:40:17: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   40 |                 printf("%d\n",ans[i]);
      |                 ^~~~~~
main.c:40:17: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:40:17: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:40:17: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

#include <stdio.h>
int main(void)
{
	int n,m,t,i,j;

	scanf("%d %d",&n,&m);
	
	int a[n][m],b[m],ans[n];

	for(i=0;i<n;i++)
	{
		for(j=0;j<m;j++)
		{
			scnaf("%d",&a[i][j]);
		}
	}



	for(i=0;i<m;i++)
	{
		scanf("%d",&b[i]);
	}

	for(i=0;i<n;i++)
	{
		t = 0;
		
		for(j=0;j<m;j++)
		{
			t = t + (a[i][j]*b[j]);
			
		}

		ans[i] = t;
		
		}

	for(i=0;i<n;i++)
	{
		printf("%d\n",ans[i]);
	}


	
	return 0;

}

Compiler output:
main.c: In function 'main':
main.c:14:25: error: implicit declaration of function 'scnaf'; did you mean 'scanf'? [-Wimplicit-function-declaration]
   14 |                         scnaf("%d",&a[i][j]);
      |                         ^~~~~
      |                         scanf
Language: C

#include<stdio.h>

int main()
{
	int n, m;
	int A[1000][1000];
	int B[1000];
	int h, w,C=0;
	scanf("%d %d", &n, &m);
	for (h = 0; h<n; h++)
	{
		for (w = 0; w<m; w++)
		{
			scanf("%d", &A[h][w]);
		}
	}
	for (h = 0; h<=n; h++)
	{
		scanf("%d", &B[h]);
	}
	for (h = 0; h < n; h++)
	{
		for (w = 0; w < m; w++)
		{
			C= C + A[h][w]*B[h];
		}
		printf("%d\n", C);
		c = 0;
	}

	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:28:17: error: 'c' undeclared (first use in this function)
   28 |                 c = 0;
      |                 ^
main.c:28:17: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>

int main()
{
	int n, m;
	int A[100][100];
	int B[1000];
	int h, w, C[100] = { 0 };
	scanf("%d %d", &n, &m);
	for (h = 0; h<n; h++)
	{
		for (w = 0; w<m; w++)
		{
			scanf("%d", &A[h][w]);
		}
	}
	for (h = 0; h<n; h++)
	{
		scanf("%d", &B[h]);
	}
	for (h = 0; h < n; h++)
	{
		for (w = 0; w < m; w++)
		{
			C[h]+= A[h][w]*B[h];
		}
		for (h = 0; h<n; h++) {
		printf("%d\n", C[h]);
	}

	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:32:1: error: expected declaration or statement at end of input
   32 | }
      | ^
Language: C

#include<stdio.h>

int main(void)
{
	int m,n;
	int i,j,k,l,ll;
	int a[100][100]={0};
	int b[100]={0};
	int c[100]={0};

	scanf("%d %d",&m,&n);

	for(i=0;i<m;i++){
		for(j=0;j<n;j++){
			scanf("%d",a[i][j]);
		}
	}
	
	for(k=0;k<n;k++){
		scanf("%d",b[k])
	}

	for(l=0;l<m;l++){
		for(ll=0;ll<m;ll++){
			c[l]=c[l]+a[l][ll]*b[ll];
		}
	printf("%d",c[l]);
	}
	returun 0;
}
	

Compiler output:
main.c: In function 'main':
main.c:20:33: error: expected ';' before '}' token
   20 |                 scanf("%d",b[k])
      |                                 ^
      |                                 ;
   21 |         }
      |         ~                        
main.c:29:9: error: 'returun' undeclared (first use in this function)
   29 |         returun 0;
      |         ^~~~~~~
main.c:29:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:29:16: error: expected ';' before numeric constant
   29 |         returun 0;
      |                ^~
      |                ;
Language: C

#include<stdio.h>

int main(void)
{
	int m,n;
	int i,j,k,l,ll;
	int a[100][100]={0};
	int b[100]={0};
	int c[100]={0};

	scanf("%d %d",&m,&n);

	for(i=0;i<m;i++){
		for(j=0;j<n;j++){
			scanf("%d",a[i][j]);
		}
	}
	
	for(k=0;k<n;k++){
		scanf("%d",b[k]);
	}

	for(l=0;l<m;l++){
		for(ll=0;ll<m;ll++){
			c[l]=c[l]+a[l][ll]*b[ll];
		}
	printf("%d",c[l]);
	}
	returun 0;
}
	

Compiler output:
main.c: In function 'main':
main.c:29:9: error: 'returun' undeclared (first use in this function)
   29 |         returun 0;
      |         ^~~~~~~
main.c:29:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:29:16: error: expected ';' before numeric constant
   29 |         returun 0;
      |                ^~
      |                ;
Language: C

#include<stdio.h>
int main(void){
int i,j,n,m;
scanf("%d %d\n",&n ,&m);
int a[n][m],b[m],add[n]={0};
for(i=0;i < n;i++){
for(j=0;j < m;j++){
scanf("%d",&a[i][j]);
}
scanf("\n");
}
for(j=0;j < m;j++){
scanf("%d\n",&b[j]);
}
for(i=0;i < n;i++){
for(j=0;j < m;j++){
add[i] += a[i][j]*b[j];
}
printf("%d\n",add[i]);
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:25: error: variable-sized object may not be initialized except with an empty initializer
    5 | int a[n][m],b[m],add[n]={0};
      |                         ^
Language: C

#include <stdio.h>
 
int main()
{
    int i,j,n,m,x;

     
    scanf("%d %d",&n,&m);
 int a[n][m], b[m]
     
    for(i=0;i<n;i++){
        for(j=0;j<m;j++){
            scanf("%d",&a[i][j]);
        }
    }
     
    for(j=0;j<m;j++){
        scanf("%d",&b[j]);
    }
     
    for(i=0;i<n;i++){
        x = 0;
        for(j=0;j<m;j++){
            x += a[i][j] * b[j];
        }
        printf("%d\n",x);
    }
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:11:5: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
   11 |     for(i=0;i<n;i++){
      |     ^~~
main.c:11:20: error: expected ';' before ')' token
   11 |     for(i=0;i<n;i++){
      |                    ^
      |                    ;
main.c:11:20: error: expected statement before ')' token
main.c:18:21: error: 'b' undeclared (first use in this function)
   18 |         scanf("%d",&b[j]);
      |                     ^
main.c:18:21: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
#include<stdlib.h>


int main(){
  int n,m,i,j,ans;
  int** A;
  int* b;
  scanf("%d%d",n,m);
  A=malloc(n*sizeof(int*));
  for(i=0;i<n;i++){
    A[i]=malloc(m*sizeof(int));}
  for(i=0;i<n;i++){
    for(j=0;j<m;j++){
      scanf("%d",A[i][j]);}}
  b=malloc(m*sizeof(int));
  for(i=0;i<m;i++){
    scanf("%d",b[i]);}
  for(i=0;i<n;i++){
    ans=0;
    for(j=0;j<m;j++){
      ans=ans+ (*A[i][j])*(*b[j]);}
    printf("%d\n",ans);}
  return 0;}

Compiler output:
main.c: In function 'main':
main.c:22:17: error: invalid type argument of unary '*' (have 'int')
   22 |       ans=ans+ (*A[i][j])*(*b[j]);}
      |                 ^~~~~~~~
main.c:22:28: error: invalid type argument of unary '*' (have 'int')
   22 |       ans=ans+ (*A[i][j])*(*b[j]);}
      |                            ^~~~~
Language: C

#include <stdio.h>

int main()
{
    int n, m, i, j, k, n;
    int A[100][100] = {0}, b[100] = {0};

    scanf("%d %d\n", &n, &m);
    
    for(i = 0; i < n; i++)
    {
        for(j = 0; j < m; j++)
        {
            scanf("%d" &A[i][j]);
        }
        printf("\n");
    }
 
    for(j = 0; j < m; i++)
    {
        scanf("%d\n", &b[j]);
    }

    for(i = 0; i < n; i++)
    {
        for(j = 0; j < m; j++)
        {
            n =+ (A[i][j] * b[j]);
        }
        printf("%d\n", n);
        n = 0;
    }

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:24: error: redeclaration of 'n' with no linkage
    5 |     int n, m, i, j, k, n;
      |                        ^
main.c:5:9: note: previous declaration of 'n' with type 'int'
    5 |     int n, m, i, j, k, n;
      |         ^
main.c:14:24: error: invalid operands to binary & (have 'char *' and 'int')
   14 |             scanf("%d" &A[i][j]);
      |                   ~~~~ ^~~~~~~~
      |                   |         |
      |                   char *    int
Language: C

#include <stdio.h>

int main()
{
    int n, m, i, j, k, t;
    int A[100][100] = {0}, b[100] = {0};

    scanf("%d %d\n", &n, &m);
    
    for(i = 0; i < n; i++)
    {
        for(j = 0; j < m; j++)
        {
            scanf("%d" &A[i][j]);
        }
        printf("\n");
    }
 
    for(j = 0; j < m; i++)
    {
        scanf("%d\n", &b[j]);
    }

    for(i = 0; i < n; i++)
    {
        for(j = 0; j < m; j++)
        {
            t =+ (A[i][j] * b[j]);
        }
        printf("%d\n", t);
        t = 0;
    }

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:14:24: error: invalid operands to binary & (have 'char *' and 'int')
   14 |             scanf("%d" &A[i][j]);
      |                   ~~~~ ^~~~~~~~
      |                   |         |
      |                   char *    int
Language: C

#include<Stdio.h>
int main(void){
	int a[101][101],b[101],c[101],n,m,i,j,sum;
	scanf("%d %d",&n,&m);
	for(i = 0;i < n;i++){
		for(j = 0;j < m;j++){
			scanf("%d",&a[i][j]);
		}
	}
	for(i = 0;i < m;i++){
		scanf("%d",&b[i]);
	}
	for(i = 0;i < n;i++){
		sum = 0;
		for(j = 0;j < m;j++){
			sum += (a[i][j]*b[j]);
		}
		c[i] = sum;
	}
	for(i = 0;i < n;i++){
		printf("%d\n",c[i]);
	}
	
	return 0;
}

Compiler output:
main.c:1:9: fatal error: Stdio.h: No such file or directory
    1 | #include<Stdio.h>
      |         ^~~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>

int main()
{
 int s[100];
 int n,n;
 int a[100][100],b[100];
 scanf("%d%d",&n,&m);
 for(int i=0;i<n;i++)
 {
  for(int j=0;j<m;j++)
  {
   scanf("%d",&a[i][j]);
  }
 }
 for(int i=0;i<m;i++)
 {
  scanf("%d",&b[i]);
 }
 for(int i=0;i<n;i++)
 {
  for(int j=0;j<m;j++)
  {
   if(i==j)
   {
    s[i]=a[i][j]+b[j];
    printf("%d\n",s[i]);
   }
  }
 }
}

Compiler output:
main.c: In function 'main':
main.c:6:8: error: redeclaration of 'n' with no linkage
    6 |  int n,n;
      |        ^
main.c:6:6: note: previous declaration of 'n' with type 'int'
    6 |  int n,n;
      |      ^
main.c:8:19: error: 'm' undeclared (first use in this function)
    8 |  scanf("%d%d",&n,&m);
      |                   ^
main.c:8:19: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
 
int main(void)
{
    int m, n, a[100][100], b,i,j;
 
    scanf("%d %d\n", &n, &m);
 
    for (i = 0; i < n; i++)
        for (j = 0; j < m; j++) {
            if (j < m - 1)
                scanf("%d ", &a[i][j]);
            else
                scanf("%d\n", &a[i][j]);
        }
 
    for (j = 0; j < m; j++) {
        scanf("%d", &b);
        for (i = 0; i < n; i++)
            a[i][j] *= b;
    }
 
    for (i = 0; i < n; i++) {
        b = 0;
        for (j = 0; j < m; j++)
            b += a[i][j];
        printf("%d\n", b);
    }
 
    return 0;

Compiler output:
main.c: In function 'main':
main.c:30:5: error: expected declaration or statement at end of input
   30 |     return 0;
      |     ^~~~~~
Language: C

 int n,m,i,j,a[100][100],b;
 scanf("%d %d\n",&n,&m);
 for(i=0;i<n;i++)
 {
  for(j=0;j<m;j++)
  {
   scanf("%d \n",&a[i][j]);
  }
 }
 for(j=0;j<m;j++)
 {
  scanf("%d",&b);
  for(i=0;i<n;i++)
  {
   a[i][j]=a[i][j]*b;
  }
 }
 for(i=0;i<n;i++)
 {
  b=0;
  for(j=0;j<m;j++)
  {
   b += a[i][j];
  
  }
 printf("%d\n", b);
 }
 return 0;
}

Compiler output:
main.c:2:8: error: expected declaration specifiers or '...' before string constant
    2 |  scanf("%d %d\n",&n,&m);
      |        ^~~~~~~~~
main.c:2:18: error: expected declaration specifiers or '...' before '&' token
    2 |  scanf("%d %d\n",&n,&m);
      |                  ^
main.c:2:21: error: expected declaration specifiers or '...' before '&' token
    2 |  scanf("%d %d\n",&n,&m);
      |                     ^
main.c:3:2: error: expected identifier or '(' before 'for'
    3 |  for(i=0;i<n;i++)
      |  ^~~
main.c:3:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    3 |  for(i=0;i<n;i++)
      |           ^
main.c:3:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
    3 |  for(i=0;i<n;i++)
      |               ^~
main.c:10:2: error: expected identifier or '(' before 'for'
   10 |  for(j=0;j<m;j++)
      |  ^~~
main.c:10:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   10 |  for(j=0;j<m;j++)
      |           ^
main.c:10:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   10 |  for(j=0;j<m;j++)
      |               ^~
main.c:18:2: error: expected identifier or '(' before 'for'
   18 |  for(i=0;i<n;i++)
      |  ^~~
main.c:18:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   18 |  for(i=0;i<n;i++)
      |           ^
main.c:18:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   18 |  for(i=0;i<n;i++)
      |               ^~
main.c:28:2: error: expected identifier or '(' before 'return'
   28 |  return 0;
      |  ^~~~~~
main.c:29:1: error: expected identifier or '(' before '}' token
   29 | }
      | ^
Language: C

 int n,m,i,j,a[100][100],b;
 scanf("%d %d\n",&n,&m);
 for(i=0;i<n;i++)
 {
  for(j=0;j<m;j++)
  {
   scanf("%d \n",&a[i][j]);
  }
 }
 for(j=0;j<m;j++)
 {
  scanf("%d",&b);
  for(i=0;i<n;i++)
  {
   a[i][j]=a[i][j]*b;
  }
 }
 for (i = 0; i < n; i++) {
        b = 0;
        for (j = 0; j < m; j++)
            b += a[i][j];
        printf("%d\n", b);
    }
 return 0;
}

Compiler output:
main.c:2:8: error: expected declaration specifiers or '...' before string constant
    2 |  scanf("%d %d\n",&n,&m);
      |        ^~~~~~~~~
main.c:2:18: error: expected declaration specifiers or '...' before '&' token
    2 |  scanf("%d %d\n",&n,&m);
      |                  ^
main.c:2:21: error: expected declaration specifiers or '...' before '&' token
    2 |  scanf("%d %d\n",&n,&m);
      |                     ^
main.c:3:2: error: expected identifier or '(' before 'for'
    3 |  for(i=0;i<n;i++)
      |  ^~~
main.c:3:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    3 |  for(i=0;i<n;i++)
      |           ^
main.c:3:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
    3 |  for(i=0;i<n;i++)
      |               ^~
main.c:10:2: error: expected identifier or '(' before 'for'
   10 |  for(j=0;j<m;j++)
      |  ^~~
main.c:10:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   10 |  for(j=0;j<m;j++)
      |           ^
main.c:10:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   10 |  for(j=0;j<m;j++)
      |               ^~
main.c:18:2: error: expected identifier or '(' before 'for'
   18 |  for (i = 0; i < n; i++) {
      |  ^~~
main.c:18:16: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   18 |  for (i = 0; i < n; i++) {
      |                ^
main.c:18:22: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   18 |  for (i = 0; i < n; i++) {
      |                      ^~
main.c:24:2: error: expected identifier or '(' before 'return'
   24 |  return 0;
      |  ^~~~~~
main.c:25:1: error: expected identifier or '(' before '}' token
   25 | }
      | ^
Language: C

#include<stdio.h>

int main(void)
{
  int n, m, i, j;

  scanf("%d %d", &n, &m);

  int A[n][m], b[m], ans[n] = {0};

  for(i = 0; i < n; i++) {
    for(j = 0; j < m; j++) {
      scanf("%d", &A[i][j]);
    }
  }

  for(i = 0; i < m; i++) {
    scanf("%d", &b[i]);
  }

  for(i = 0; i < n; i++) {
    for(j = 0; j < m; j++) {
      ans[i] += A[i][j] * b[j];
    }
  }

  for(i = 0; i < n; i++) {
    printf("%d\n", ans[i]);
  }

  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:31: error: variable-sized object may not be initialized except with an empty initializer
    9 |   int A[n][m], b[m], ans[n] = {0};
      |                               ^
Language: C

#include<iostream>
#include<vector>
using namespace std;
int main(){
    int i,j,n,m,temp;
    vector< vector <int> > a;
    vector<int> b;
    cin>> n>> m;
    a.resize(n);
    b.resize(m);
    for(i=0;i<n;i++){
        a[i].resize(m);
    }
    for(i=0;i<n;i++){
        for(j=0;j<m;j++){
            a[i][j]=0;
        }
    }
    for(i=0;i<n;i++){
        for(j=0;j<m;j++){
            cin>> a[i][j];
        }
    }
    for(j=0;j<m;j++){
        cin>> b[j];
    }
    for(i=0;i<n;i++){
        temp=0;
        for(j=0;j<m;j++){
            temp+=a[i][j]*b[j];
        }
        cout<< temp<< endl;
    }
     
    return 0;
}

Compiler output:
main.c:1:9: fatal error: iostream: No such file or directory
    1 | #include<iostream>
      |         ^~~~~~~~~~
compilation terminated.
Language: C

#include <stdio.h>
int main(void){
????????//scan
????????int n,m;
????????scanf("%d %d\n",&n,&m);
????????int a[n][m];
????????int b[m][1];
????????int c[n][1];
????????int i,j;
????????for(i=0;i<n;i++){
????????????????for(j=0;j<m;j++){
????????????????????????if(j==m-1){
????????????????????????????????scanf("%d\n",&a[i][j]);
????????????????????????}else{
????????????????????????????????scanf("%d ",&a[i][j]);
????????????????????????}
????????????????}
????????}
????????int k;
????????for(k=0;k<m;k++){
????????????????scanf("%d\n",&b[k][0]);
????????}
????????//end scan
????????int l;
????????for(l=0;l<n;l++){
????????????????int x;
????????????????c[l][0] = 0;
????????????????for(x=0;x<m;x++){
????????????????????????c[l][0] = c[l][0] + (a[l][x]*b[x][0]);
????????????????}
????????}
????????int y;
????????for(y=0;y<n;y++){
????????????????printf("%d\n",c[y][0]);
????????}
????????return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:1: error: expected expression before '?' token
    3 | ????????//scan
      | ^
main.c:3:7: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
    3 | ????????//scan
main.c:5:1: error: expected expression before '?' token
    5 | ????????scanf("%d %d\n",&n,&m);
      | ^
main.c:5:26: error: 'n' undeclared (first use in this function)
    5 | ????????scanf("%d %d\n",&n,&m);
      |                          ^
main.c:5:26: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:29: error: 'm' undeclared (first use in this function)
    5 | ????????scanf("%d %d\n",&n,&m);
      |                             ^
main.c:6:1: error: expected expression before '?' token
    6 | ????????int a[n][m];
      | ^
main.c:7:1: error: expected expression before '?' token
    7 | ????????int b[m][1];
      | ^
main.c:8:1: error: expected expression before '?' token
    8 | ????????int c[n][1];
      | ^
main.c:9:1: error: expected expression before '?' token
    9 | ????????int i,j;
      | ^
main.c:10:1: error: expected expression before '?' token
   10 | ????????for(i=0;i<n;i++){
      | ^
main.c:20:1: error: expected expression before '?' token
   20 | ????????for(k=0;k<m;k++){
      | ^
main.c:23:7: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
   23 | ????????//end scan
main.c:25:1: error: expected expression before '?' token
   25 | ????????for(l=0;l<n;l++){
      | ^
main.c:33:1: error: expected expression before '?' token
   33 | ????????for(y=0;y<n;y++){
      | ^
Language: C

#include <stdio.h>
int main(void)
{
????????
????????int n,m;
????????scanf("%d %d\n",&n,&m);
????????int a[n][m];
????????int b[m][1];
????????int c[n][1];
????????int i,j;
????????for(i=0;i<n;i++){
????????????????for(j=0;j<m;j++){
????????????????????????if(j==m-1){
????????????????????????????????scanf("%d\n",&a[i][j]);
????????????????????????}
else
{
????????????????????????????????scanf("%d ",&a[i][j]);
????????????????????????}
????????????????}
????????}
????????int k;
????????for(k=0;k<m;k++){
????????????????scanf("%d\n",&b[k][0]);
????????}
????????
????????int l;
????????for(l=0;l<n;l++){
????????????????int x;
????????????????c[l][0] = 0;
????????????????for(x=0;x<m;x++){
????????????????????????c[l][0] = c[l][0] + (a[l][x]*b[x][0]);
????????????????}
????????}
????????int y;
????????for(y=0;y<n;y++)
{
????????????????printf("%d\n",c[y][0]);
????????}
????????return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:1: error: expected expression before '?' token
    4 | ????????
      | ^
main.c:6:1: error: expected expression before '?' token
    6 | ????????scanf("%d %d\n",&n,&m);
      | ^
main.c:6:26: error: 'n' undeclared (first use in this function)
    6 | ????????scanf("%d %d\n",&n,&m);
      |                          ^
main.c:6:26: note: each undeclared identifier is reported only once for each function it appears in
main.c:6:29: error: 'm' undeclared (first use in this function)
    6 | ????????scanf("%d %d\n",&n,&m);
      |                             ^
main.c:7:1: error: expected expression before '?' token
    7 | ????????int a[n][m];
      | ^
main.c:8:1: error: expected expression before '?' token
    8 | ????????int b[m][1];
      | ^
main.c:9:1: error: expected expression before '?' token
    9 | ????????int c[n][1];
      | ^
main.c:10:1: error: expected expression before '?' token
   10 | ????????int i,j;
      | ^
main.c:11:1: error: expected expression before '?' token
   11 | ????????for(i=0;i<n;i++){
      | ^
main.c:23:1: error: expected expression before '?' token
   23 | ????????for(k=0;k<m;k++){
      | ^
main.c:28:1: error: expected expression before '?' token
   28 | ????????for(l=0;l<n;l++){
      | ^
main.c:36:1: error: expected expression before '?' token
   36 | ????????for(y=0;y<n;y++)
      | ^
Language: C

#include <stdio.h>
int main(void){
????????
????????int n,m;
????????scanf("%d %d\n",&n,&m);
????????int a[n][m];
????????int b[m][1];
????????int c[n][1];
????????int i,j;
????????for(i=0;i<n;i++){
????????????????for(j=0;j<m;j++){
????????????????????????if(j==m-1){
????????????????????????????????scanf("%d\n",&a[i][j]);
????????????????????????}else{
????????????????????????????????scanf("%d ",&a[i][j]);
????????????????????????}
????????????????}
????????}
????????int k;
????????for(k=0;k<m;k++){
????????????????scanf("%d\n",&b[k][0]);
????????}
????????
????????int l;
????????for(l=0;l<n;l++){
????????????????int x;
????????????????c[l][0] = 0;
????????????????for(x=0;x<m;x++){
????????????????????????c[l][0] = c[l][0] + (a[l][x]*b[x][0]);
????????????????}
????????}
????????int y;
????????for(y=0;y<n;y++){
????????????????printf("%d\n",c[y][0]);
????????}
????????return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:1: error: expected expression before '?' token
    3 | ????????
      | ^
main.c:5:1: error: expected expression before '?' token
    5 | ????????scanf("%d %d\n",&n,&m);
      | ^
main.c:5:26: error: 'n' undeclared (first use in this function)
    5 | ????????scanf("%d %d\n",&n,&m);
      |                          ^
main.c:5:26: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:29: error: 'm' undeclared (first use in this function)
    5 | ????????scanf("%d %d\n",&n,&m);
      |                             ^
main.c:6:1: error: expected expression before '?' token
    6 | ????????int a[n][m];
      | ^
main.c:7:1: error: expected expression before '?' token
    7 | ????????int b[m][1];
      | ^
main.c:8:1: error: expected expression before '?' token
    8 | ????????int c[n][1];
      | ^
main.c:9:1: error: expected expression before '?' token
    9 | ????????int i,j;
      | ^
main.c:10:1: error: expected expression before '?' token
   10 | ????????for(i=0;i<n;i++){
      | ^
main.c:20:1: error: expected expression before '?' token
   20 | ????????for(k=0;k<m;k++){
      | ^
main.c:25:1: error: expected expression before '?' token
   25 | ????????for(l=0;l<n;l++){
      | ^
main.c:33:1: error: expected expression before '?' token
   33 | ????????for(y=0;y<n;y++){
      | ^
Language: C

#include<stdio.h>
int main(void){
  int n,m,i,j,k;
  scanf("%d %d",&n,&m);
  int a[n][m];
  for(i=1;i<=n;i++){
    for(j=1;j<=m;j++){
      scanf("%d",&a[i-1][j-1]);
    }
  }
  int b[m];
  for(j=1;j<=m;j++){
    scanf("%d",&b[j-1]);
  }
/*  int c[n];
  for(k=1;k<=n;k++){
    c[k-1]=0; //????????????0???
    }
*/
  for(i=1;i<=n;i++){
    c[i-1]=0;
    for(j=1;j<=m;j++){
      c[i-1]+=a[i-1][j-1]*b[j-1];
    }
    printf("%d\n",c[i-1]);
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:21:5: error: 'c' undeclared (first use in this function)
   21 |     c[i-1]=0;
      |     ^
main.c:21:5: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int main(void){
  int n,m,i,j,k;
  scanf("%d %d",&n,&m);
  int a[n][m];
  for(i=1;i<=n;i++){
    for(j=1;j<=m;j++){
      scanf("%d",&a[i-1][j-1]);
    }
  }
  int b[m];
  for(j=1;j<=m;j++){
    scanf("%d",&b[j-1]);
  }
  int c[n];
/*  for(k=1;k<=n;k++){
    c[k-1]=0; //????????????0???
    }
*/
  for(i=1;i<=n;i++){
    c[i-1]=0;???//
    for(j=1;j<=m;j++){
      c[i-1]+=a[i-1][j-1]*b[j-1];
    }
    printf("%d\n",c[i-1]);
  }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:21:15: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
   21 |     c[i-1]=0;???//
main.c:21:14: error: expected expression before '?' token
   21 |     c[i-1]=0;???//
      |              ^
Language: C

#include <stdio.h>

int main(void){
    int n,m,i,j;
    scanf("%d %d",&n,&m);
    int matrix[n][m];
    int vector[m];
    int ans[n] = {0};
    for(i = 0;i<n;i++){
        for(j=0;j<m;j++){
            scanf("%d",&matrix[i][j]);
        }
    }
    for(i = 0;i<m;i++){
        scanf("%d",&vector[i]);
    }
    for(i = 0;i<n;i++){
        for(j = 0;j<m;j++){
            ans[i] += matrix[i][j] * vector[j];
        }
        printf("%d\n",ans[i]);
    }
}

Compiler output:
main.c: In function 'main':
main.c:8:18: error: variable-sized object may not be initialized except with an empty initializer
    8 |     int ans[n] = {0};
      |                  ^
Language: C

#include <stdio.h>

int main(){
int a,b,i,j;
scanf("%d %d",&a,&b);
int mat[a][b],vec[b];
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      scanf("%d",&a[i][j]);
   }
}
for(i=0;i<b;i++){
   scanf("%d",vec[i]);
}
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      printf("%d",a[i][j]*b[j]);
   }
   printf("\n");
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:20: error: subscripted value is neither array nor pointer nor vector
    9 |       scanf("%d",&a[i][j]);
      |                    ^
main.c:17:20: error: subscripted value is neither array nor pointer nor vector
   17 |       printf("%d",a[i][j]*b[j]);
      |                    ^
main.c:17:28: error: subscripted value is neither array nor pointer nor vector
   17 |       printf("%d",a[i][j]*b[j]);
      |                            ^
Language: C

#include <stdio.h>

int main(){
int a,b,i,j;
scanf("%d %d",&a,&b);
int mat[a][b],vec[b];
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      scanf("%d",&a[i][j]);
   }
}
for(i=0;i<b;i++){
   scanf("%d",vec[i]);
}
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      printf("%d",mat[i][j]*vec[j]);
   }
   printf("\n");
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:20: error: subscripted value is neither array nor pointer nor vector
    9 |       scanf("%d",&a[i][j]);
      |                    ^
Language: C

#include <stdio.h>

int main(){
int a,b,i,j;
scanf("%d %d",&a,&b);
int mat[a][b],vec[b];
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      scanf("%d",&a[i][j]);
   }
}
for(i=0;i<b;i++){
   scanf("%d",&vec[i]);
}
for(i=0;i<a;i++){
   for(j=0;j<b;j++){
      printf("%d",mat[i][j]*vec[j]);
   }
   printf("\n");
}
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:9:20: error: subscripted value is neither array nor pointer nor vector
    9 |       scanf("%d",&a[i][j]);
      |                    ^
Language: C

#include <stdio.h>

int main(){
    int n, m, a[100][100], b[100];
    scanf("%d %d", &n, &m);
    
    for (int i=1; i<=n; i++){
        for (int j=1; j<=m; j++){
            scanf("%d",&a[i][j]);
        }
    }
    for (int i=1; i<=m; i++){
        scanf("%d", &b[i]);
    }
    
    for (int i=1; i<=n; i++){
int ans=0
        for (int j=1; j<=m; j++){
            ans += (a[i][j] * b[j]);
        }
printf("%d\n", ans);
    }

    for (int j=1; j<=n; j++){
      printf("%d\n", c[j]);
    }
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:18:9: error: expected ',' or ';' before 'for'
   18 |         for (int j=1; j<=m; j++){
      |         ^~~
main.c:18:23: error: 'j' undeclared (first use in this function)
   18 |         for (int j=1; j<=m; j++){
      |                       ^
main.c:18:23: note: each undeclared identifier is reported only once for each function it appears in
main.c:18:32: error: expected ';' before ')' token
   18 |         for (int j=1; j<=m; j++){
      |                                ^
      |                                ;
main.c:18:32: error: expected statement before ')' token
main.c:25:22: error: 'c' undeclared (first use in this function)
   25 |       printf("%d\n", c[j]);
      |                      ^
Language: C

#include <stdio.h>

int main(){
    int n, m, a[100][100], b[100];
    scanf("%d %d", &n, &m);
    
    for (int i=1; i<=n; i++){
        for (int j=1; j<=m; j++){
            scanf("%d",&a[i][j]);
        }
    }
    for (int i=1; i<=m; i++){
        scanf("%d", &b[i]);
    }
    
    for (int i=1; i<=n; i++){
int ans=0
        for (int j=1; j<=m; j++){
            ans += (a[i][j] * b[j]);
        }
printf("%d\n", ans);
    }
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:18:9: error: expected ',' or ';' before 'for'
   18 |         for (int j=1; j<=m; j++){
      |         ^~~
main.c:18:23: error: 'j' undeclared (first use in this function)
   18 |         for (int j=1; j<=m; j++){
      |                       ^
main.c:18:23: note: each undeclared identifier is reported only once for each function it appears in
main.c:18:32: error: expected ';' before ')' token
   18 |         for (int j=1; j<=m; j++){
      |                                ^
      |                                ;
main.c:18:32: error: expected statement before ')' token
Language: C

#include <stdio.h>

int main(void)
{
	int a[100][100], b[100], i, j, n, m, c[100] ;

	scanf_s("%d %d", &n, &m);

		for (i = 0; i < n; i++) {
			for (j = 0; j < m; j++) {
				scanf("%d ", &a[i][j]);
			}
		}

		for (i = 0; i < m; i++) {
			scanf("%d", &b[i]);
		}

		c[0] = 0;

		for (i = 0; i < n; i++) {
			for (j = 0; j < m; j++) {
				if (j == 0) {
					c[i] = a[i][j] * b[j];
				}
				else
				c[i] = a[i][j] * b[j] + c[i];
			}
		}





		for (i = 0; i <n; i++) {
			printf("%d\n", c[i]);
		}


		
	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:7:9: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    7 |         scanf_s("%d %d", &n, &m);
      |         ^~~~~~~
      |         scanf
Language: C

#include <stdio.h>

int main(void)
{
	int i, j, m, n, **A, *v, c;
	scanf("%d %d", &n, &m);

	A = (int *)malloc(sizeof(int *) * n);
	for (i = 0; i < n; i++) {
		A[i] = (int *)malloc(sizeof(int) * m);
	}
	v = (int *)malloc(sizeof(int) * n);

	for (i = 0; i < n; i++) {
		for (j = 0; j < m; j++) {
			scanf("%d", &A[i][j];
		}
	}
	for (i = 0; i < n; i++) {
		scanf("%d", &v[i]);
	}
	for (i = 0; i < n; i++) {
		c = 0;
		for (j = 0; j < m; j++) {
			c += A[i][j] * v[i];
		}
		printf("%d\n", c);
	}

	return 0;
}






Compiler output:
main.c: In function 'main':
main.c:8:20: error: implicit declaration of function 'malloc' [-Wimplicit-function-declaration]
    8 |         A = (int *)malloc(sizeof(int *) * n);
      |                    ^~~~~~
main.c:2:1: note: include '<stdlib.h>' or provide a declaration of 'malloc'
    1 | #include <stdio.h>
  +++ |+#include <stdlib.h>
    2 | 
main.c:8:20: warning: incompatible implicit declaration of built-in function 'malloc' [-Wbuiltin-declaration-mismatch]
    8 |         A = (int *)malloc(sizeof(int *) * n);
      |                    ^~~~~~
main.c:8:20: note: include '<stdlib.h>' or provide a declaration of 'malloc'
main.c:8:11: error: assignment to 'int **' from incompatible pointer type 'int *' [-Wincompatible-pointer-types]
    8 |         A = (int *)malloc(sizeof(int *) * n);
      |           ^
main.c:16:45: error: expected ')' before ';' token
   16 |                         scanf("%d", &A[i][j];
      |                              ~              ^
      |                                             )
main.c:16:46: error: expected ';' before '}' token
   16 |                         scanf("%d", &A[i][j];
      |                                              ^
      |                                              ;
   17 |                 }
      |                 ~
Language: C

#include <stdio.h>
using namespace std;

int main() {

	int n, m;
	scanf("%d",&n);
	scanf("%d", &m);
	int a[100][100];
	for (int i = 0; i < n; i++) {
		for (int j = 0; j < m; j++) {
			scanf("%d", &a[i][j]);
		}
	}
	int b[100];
	for (int i = 0; i < m; i++) {
		scanf("%d", &b[i]);
	}
	int c[100];
	for (int i = 0; i < n; i++) {
		for (int j = 0; j < m; j++) {
			c[i] = a[i][j] * b[i];
		}
	}
	for (int i = 0; i < m; i++) {
		printf("%d", c[i]);
	}

	return 0;
}


Compiler output:
main.c:2:1: error: unknown type name 'using'
    2 | using namespace std;
      | ^~~~~
main.c:2:17: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'std'
    2 | using namespace std;
      |                 ^~~
Language: C

#include<stdio.h>
int main(){
    int inact[100][100];
    int act[100];
    int ans[100];
    int row, col;
    int i, j;
    for(i = 0;i < 100;i++){
        for(j = 0;j < 100;j++){
            act[i][j] = 0;
        }
        inact[i] = 0;
        ans[i] = 0;
    }
    scanf("%d %d", &row, &col);
    for(i = 0;i < row;i++){
        for(j = 0;j < col;j++){
            scanf("%d", &inact[i][j]);
        }
    }
    for(i = 0;i < row;i++){
        scanf("%d", &act[i]);
    }
    for(i = 0;i < row;i++){
        for(j = 0;j < col;j++){
            ans[i] += inact[j][i] * act[j];
        }
    }
    for(i = 0;i < row;i++){
        printf("%d\n", act[i]);
    }
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:10:19: error: subscripted value is neither array nor pointer nor vector
   10 |             act[i][j] = 0;
      |                   ^
main.c:12:18: error: assignment to expression with array type
   12 |         inact[i] = 0;
      |                  ^
Language: C

#include<stdio.h>
int main(){
    unsigned int inact[100][100];
    unsignedint act[100];
    unsignedint ans[100];
    unsignedint row, col;
    unsignedint i, j;
    for(i = 0;i < 100;i++){
        for(j = 0;j < 100;j++){
            inact[i][j] = 0;
        }
        act[i] = 0;
        ans[i] = 0;
    }
    scanf("%d %d", &row, &col);
    for(i = 0;i < row;i++){
        for(j = 0;j < col;j++){
            scanf("%d", &inact[i][j]);
        }
    }
    for(i = 0;i < col;i++){
        scanf("%d", &act[i]);
    }
    for(i = 0;i < row;i++){
        for(j = 0;j < col;j++){
            ans[i] += inact[i][j] * act[j];
        }
    }
    for(i = 0;i < row;i++){
        printf("%d\n", ans[i]);
    }
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:4:5: error: unknown type name 'unsignedint'; did you mean 'unsigned int'?
    4 |     unsignedint act[100];
      |     ^~~~~~~~~~~
      |     unsigned int
main.c:5:5: error: unknown type name 'unsignedint'; did you mean 'unsigned int'?
    5 |     unsignedint ans[100];
      |     ^~~~~~~~~~~
      |     unsigned int
main.c:6:5: error: unknown type name 'unsignedint'; did you mean 'unsigned int'?
    6 |     unsignedint row, col;
      |     ^~~~~~~~~~~
      |     unsigned int
main.c:7:5: error: unknown type name 'unsignedint'; did you mean 'unsigned int'?
    7 |     unsignedint i, j;
      |     ^~~~~~~~~~~
      |     unsigned int
Language: C

#include<stdio.h>
int main(){
    unsigned long ulW_D_inact[100][100];    /* 行列Ａの格納用変数 */
    unsigned long ulW_D_act[100];           /* 行列Ｂの格納用変数 */
    unsigned long ulW_D_ans[100];           /* 積の格納用変数 */
    unsigned short usW_D_row, usW_D_col;          /* 行列の要素数の格納用変数 */
    unsigned short usW_C_i, usW_C_j;              /* ループ変数 */

    /* 配列の初期化 */
    for(usW_C_i = 0;usW_C_i < 100;usW_C_i++){
        for(usW_C_j = 0;usW_C_j < 100;usW_C_j++){
            ulW_D_inact[usW_C_i][usW_C_j] = 0;
        }
        ulW_D_act[i] = 0;
        ulW_D_ans[i] = 0;
    }

    /* 行列の要素数の入力 */
    scanf("%d %d", &usW_D_row, &usW_D_col);

    /* 行列Ａの入力 */
    for(usW_C_i = 0;usW_C_i < usW_D_row;usW_C_i++){
        for(usW_C_j = 0;usW_C_j < usW_D_col;usW_C_j++){
            scanf("%d", &ulW_D_inact[usW_C_i][usW_C_j]);
        }
    }

    /* 行列Ｂの入力 */
    for(usW_C_i = 0;usW_C_i < usW_D_col;usW_C_i++){
        scanf("%d", &ulW_D_act[usW_C_i]);
    }

    /* ＡとＢの積の計算 */
    for(usW_C_i = 0;usW_C_i < usW_D_row;usW_C_i++){
        for(usW_C_j = 0;usW_C_j < usW_D_col;usW_C_j++){
            /* i番目の積の計算 */
            ulW_D_ans[usW_C_i] += ulW_D_inact[usW_C_i][usW_C_j] * ulW_D_act[usW_C_j];
        }
    }
    /* 積の出力 */
    for(usW_C_i = 0;usW_C_i < usW_D_row;usW_C_i++){
        /* i番目の積の出力 */
        printf("%d\n", ulW_D_ans[usW_C_i]);
    }
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:14:19: error: 'i' undeclared (first use in this function)
   14 |         ulW_D_act[i] = 0;
      |                   ^
main.c:14:19: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>

int main(void){
  int n,m,A[][],b[],c;
  scanf("%d %d",&n,&m);
  for(int i = 0; i < n; i++){
    for(int j = 0; j < m; j++){
      A[i][j] = 0;
      b[j] = 0;
    }
  }
  for(i = 0; i < n; i++){
    for(j = 0; j < m; j++){
      scanf("%d",&A[i][j]);
    }
  }
  for(j = 0; j< m; j++){
    scanf("%d",b[j]);
  }

  for(i = 0; i < n; i++){
    for(j = 0; j < m; j++){
      A[i][j] += c;
    }
    printf("%d\n",b[j] + a[i][j]);
  }
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:4:11: error: array type has incomplete element type 'int[]'
    4 |   int n,m,A[][],b[],c;
      |           ^
main.c:4:11: note: declaration of 'A' as multidimensional array must have bounds for all dimensions except the first
main.c:4:17: error: array size missing in 'b'
    4 |   int n,m,A[][],b[],c;
      |                 ^
main.c:12:7: error: 'i' undeclared (first use in this function)
   12 |   for(i = 0; i < n; i++){
      |       ^
main.c:12:7: note: each undeclared identifier is reported only once for each function it appears in
main.c:13:9: error: 'j' undeclared (first use in this function)
   13 |     for(j = 0; j < m; j++){
      |         ^
main.c:25:26: error: 'a' undeclared (first use in this function)
   25 |     printf("%d\n",b[j] + a[i][j]);
      |                          ^
Language: C

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>

int main(void){
    int m,n,i,j;
    int **A;
    int *B;#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>

int main(void){
    int m,n,i,j;
    int **A;
    int *B;
    int *C;
    
    scanf("%d %d",&n,&m);
    
    if(m<1||n<1||100<m||100<n){
        printf("error\n");
        return 0;
    }
    
    A=malloc(sizeof(int *) * m);
    
    for(i=0;i<m;i++){
        A[i]=malloc(sizeof(int) * m);
    }
    
    B=(int*)calloc(m,sizeof(int));
    C=(int*)calloc(n,sizeof(int));
    
    for(i=0;i<n;i++){
        for(j=0;j<m;j++){
            scanf("%d",&A[j][i]);
            if(A[j][i]<0||1000<A[j][i]){
                printf("error\n");
                return 0;
            }
        }
    }
    
    for(i=0;i<m;i++){
        scanf("%d",&B[i]);
        if(B[i]<0||1000<B[i]){
            printf("error\n");
            return 0;
        }
    }
    
    
    for(i=0;i<n;i++){
        C[i]=0;
        for(j=0;j<m;j++){
            C[i]+=A[j][i]*B[j];
        }
    }
    
    for(i=0;i<m;i++){
        free(A[i]);
    }
    free(A);
    free(B);
    
    for(i=0;i<n;i++){
        printf("%d\n",C[i]);
    }
    
    return 0;
}
    int *C;
    
    scanf("%d %d",&n,&m);
    
    if(m<1||n<1||100<m||100<n){
        printf("error\n");
        return 0;
    }
    
    A=malloc(sizeof(int *) * m);
    
    for(i=0;i<m;i++){
        A[i]=malloc(sizeof(int) * m);
    }
    
    B=(int*)calloc(m,sizeof(int));
    C=(int*)calloc(n,sizeof(int));
    
    for(i=0;i<n;i++){
        for(j=0;j<m;j++){
            //printf("%d %d:%d %d\n",n,m,i,j);
            scanf("%d",&A[j][i]);
            if(A[j][i]<0||1000<A[j][i]){
                printf("error\n");
                return 0;
            }
        }
    }
    
    for(i=0;i<m;i++){
        scanf("%d",&B[i]);
        if(B[i]<0||1000<B[i]){
            printf("error\n");
            return 0;
        }
    }
    
    
    for(i=0;i<n;i++){
        C[i]=0;
        for(j=0;j<m;j++){
            C[i]+=A[j][i]*B[j];
        }
    }
    
    for(i=0;i<n;i++){
        printf("%d\n",C[i]);
    }
    
    
   
    free(A);
    free(B);
    
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:9:12: error: stray '#' in program
    9 |     int *B;#include <stdio.h>
      |            ^
main.c:9:13: error: 'include' undeclared (first use in this function)
    9 |     int *B;#include <stdio.h>
      |             ^~~~~~~
main.c:9:13: note: each undeclared identifier is reported only once for each function it appears in
main.c:9:22: error: 'stdio' undeclared (first use in this function); did you mean 'stdin'?
    9 |     int *B;#include <stdio.h>
      |                      ^~~~~
      |                      stdin
main.c:14:1: error: expected expression before 'int'
   14 | int main(void){
      | ^~~
main.c:90:5: error: 'C' undeclared (first use in this function)
   90 |     C=(int*)calloc(n,sizeof(int));
      |     ^
Language: C

#include <stdio.h>

int main(){
    int A[100][100], b[100], c[100] = {0}, n, m, i, j;
    scanf("%d%d", &n, &m);
    for(i=0; i<n; i++) for(j=0; j<m; j++) scanf("%d", A[i][j]);
    for(j=0; j<m; j++) scanf("%d", b[j]);
    for(i=0; i<n; i++) for(j=0; j<m; j++) c[i] += A[i][j] * b[j];
    for(i=0; i<n; i++) printf("%d\n", c[i])
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:9:44: error: expected ';' before 'return'
    9 |     for(i=0; i<n; i++) printf("%d\n", c[i])
      |                                            ^
      |                                            ;
   10 |     return 0;
      |     ~~~~~~
Language: C



#include <stdio.h>
 #include<string.h> int main()
 {
 int a[101][101];
 int b[101];
 int n,m;
 scanf("%d %d",&n,&m);
 for(int i=0;
i<n;
i++)
{
 for(int j=0;
j<m;
j++)
{
 scanf("%d",&a[i][j]);
 }
 }
 for(int i=0;
i<m;
i++)
{
 scanf("%d",&b[i]);
 }
 for(int i=0;
i<n;
i++)
{
 int ans=0;
 for(int j=0;
j<m;
j++)
{
 ans+=a[i][j]*b[j];
 }
 printf("%d\n",ans);
 }
 }
 



Compiler output:
main.c:4:21: warning: extra tokens at end of #include directive
    4 |  #include<string.h> int main()
      |                     ^~~
main.c:5:2: error: expected identifier or '(' before '{' token
    5 |  {
      |  ^
Language: C

#include <stdio.h> #include<string.h> int main()
{
    int a[101][101];
    int b[101];
    int n,m;
    scanf("%d %d",&n,&m);
    for(int i=0;
    i<n;
    i++)
    {
        for(int j=0;
        j<m;
        j++)
        {
            scanf("%d",&a[i][j]);
            
        } 
    }
    for(int i=0;
    i<m;
    i++)
    {
        scanf("%d",&b[i]);
        }
        for(int i=0;
        i<n;
        i++)
        {
            int ans=0; 
            for(int j=0;
            j<m;
            j++)
            {
                ans+=a[i][j]*b[j];
                }
                printf("%d\n",ans);
                }
                } 


Compiler output:
main.c:1:20: warning: extra tokens at end of #include directive
    1 | #include <stdio.h> #include<string.h> int main()
      |                    ^
main.c:2:1: error: expected identifier or '(' before '{' token
    2 | {
      | ^
Language: C

#include<stdio.h>
#define MAX 100
int main(){
  int A[MAX][MAX];
  int B[MAX];
  int C[MAX];
  int n,m,i,j;
  scanf("%d%d",&n,&m);
  for(i=0;i<n;i++)
    for(j=0;j<m;j++)
      scanf("%d",&A[i][j]);

  for(j=0;j<m;j++)
    scanf("%d",&B[j]);

  for(i=0;i<n;i++)
    C[i]=0;

  for(i=0;i<n;i++)
    for(j=0;j<m;j++)
      C[i]+=A[i][j]*B[j];

  for(j=0;j<n;j++)
    printf("%d\n",C[j]);

  return 0;



Compiler output:
main.c: In function 'main':
main.c:26:3: error: expected declaration or statement at end of input
   26 |   return 0;
      |   ^~~~~~
Language: C

#include<stdio.h>
#define MAX 100
int main(){
  int A[MAX][MAX];
  int B[MAX];
  int C[MAX];
  int n,m,i,j;
  scanf("%d%d",&n,&m);
  for(i=0;i<n;i++)
    for(j=0;j<m;j++)
      scanf("%d",&A[i][j]);

  for(j=0;j<m;j++)
    scanf("%d",&B[j]);

  for(i=0;i<n;i++)
    C[i]=0;

  for(i=0;i<n;i++)
    for(j=0;j<m;j++)
      C[i]+=A[i][j]*B[j];

  for(j=0;j<n;j++)
    printf("%d\n",C[j]);

  return 0;
  ｝



Compiler output:
main.c: In function 'main':
main.c:27:3: error: '\U0000ff5d' undeclared (first use in this function)
   27 |   ｝
      |   ^~
main.c:27:3: note: each undeclared identifier is reported only once for each function it appears in
main.c:27:5: error: expected ';' at end of input
   27 |   ｝
      |     ^
      |     ;
   28 | 
main.c:27:3: error: expected declaration or statement at end of input
   27 |   ｝
      |   ^~