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


#include<stdio.h>


int isprime(int *,int);

#define N 10000

main(){
  int i,count,num[N];
  scanf("%d",&count);
  for(i=0;i<count;i++){
    scanf("%d",&num[i]);#include<stdio.h>


int isprime(int *,int);

#define N 10000

main(){
  int i,count,num[N];
  scanf("%d",&count);
  for(i=0;i<count;i++){
    scanf("%d",&num[i]);
  }
  printf("%d\n",insprime(num,count));
  return 0;
}


int insprime(int *x,int count){
    int i,j,y,a=0;
    for(i=0;i<count;i++){
      y=0;
      for(j = 1; j <= x[i] ;j++){
	if(x[i]%j==0) y++;
      }
      if(y==2) a = a+1;
    } 
    return a;  
  }

  }
  printf("%d\n",insprime(num,count));
  return 0;
}


int insprime(int *x,int count){
    int i,j,y,a=0;
    for(i=0;i<count;i++){
      y=0;
      for(j = 1; j <= x[i] ;j++){
	if(x[i]%j==0) y++;
      }
      if(y==2) a = a+1;
    } 
    return a;  
  }

Compiler output:
main.c:9:1: error: return type defaults to 'int' [-Wimplicit-int]
    9 | main(){
      | ^~~~
main.c: In function 'main':
main.c:13:25: error: stray '#' in program
   13 |     scanf("%d",&num[i]);#include<stdio.h>
      |                         ^
main.c:13:26: error: 'include' undeclared (first use in this function)
   13 |     scanf("%d",&num[i]);#include<stdio.h>
      |                          ^~~~~~~
main.c:13:26: note: each undeclared identifier is reported only once for each function it appears in
main.c:13:34: error: 'stdio' undeclared (first use in this function); did you mean 'stdin'?
   13 |     scanf("%d",&num[i]);#include<stdio.h>
      |                                  ^~~~~
      |                                  stdin
main.c:16:1: error: expected expression before 'int'
   16 | int isprime(int *,int);
      | ^~~
main.c:20:7: error: expected ';' before '{' token
   20 | main(){
      |       ^
      |       ;
main.c:44:17: error: implicit declaration of function 'insprime'; did you mean 'isprime'? [-Wimplicit-function-declaration]
   44 |   printf("%d\n",insprime(num,count));
      |                 ^~~~~~~~
      |                 isprime
Language: C

#include<stdio.h>


int isprime(int *,int);

#define N 10000

main(){
  int i,count,num[N];
  scanf("%d",&count);
  for(i=0;i<count;i++){
    scanf("%d",&num[i]);#include<stdio.h>


int isprime(int *,int);

#define N 10000

main(){
  int i,count,num[N];
  scanf("%d",&count);
  for(i=0;i<count;i++){
    scanf("%d",&num[i]);
  }
  printf("%d\n",insprime(num,count));
  return 0;
}


int insprime(int *x,int count){
    int i,j,y,a=0;
    for(i=0;i<count;i++){
      y=0;
      for(j = 1; j <= x[i] ;j++){
	if(x[i]%j==0) y++;
      }
      if(y==2) a = a+1;
    } 
    return a;  
  }

  }
  printf("%d\n",insprime(num,count));
  return 0;
}


int insprime(int *x,int count){
    int i,j,y,a=0;
    for(i=0;i<count;i++){
      y=0;
      for(j = 1; j <= x[i] ;j++){
	if(x[i]%j==0) y++;
      }
      if(y==2) a = a+1;
    } 
    return a;  
  }

Compiler output:
main.c:8:1: error: return type defaults to 'int' [-Wimplicit-int]
    8 | main(){
      | ^~~~
main.c: In function 'main':
main.c:12:25: error: stray '#' in program
   12 |     scanf("%d",&num[i]);#include<stdio.h>
      |                         ^
main.c:12:26: error: 'include' undeclared (first use in this function)
   12 |     scanf("%d",&num[i]);#include<stdio.h>
      |                          ^~~~~~~
main.c:12:26: note: each undeclared identifier is reported only once for each function it appears in
main.c:12:34: error: 'stdio' undeclared (first use in this function); did you mean 'stdin'?
   12 |     scanf("%d",&num[i]);#include<stdio.h>
      |                                  ^~~~~
      |                                  stdin
main.c:15:1: error: expected expression before 'int'
   15 | int isprime(int *,int);
      | ^~~
main.c:19:7: error: expected ';' before '{' token
   19 | main(){
      |       ^
      |       ;
main.c:43:17: error: implicit declaration of function 'insprime'; did you mean 'isprime'? [-Wimplicit-function-declaration]
   43 |   printf("%d\n",insprime(num,count));
      |                 ^~~~~~~~
      |                 isprime
Language: C

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

main()
{
int n, i, j, flag, count=0;
scanf(???%d???, &n???);

for(i=0; i<n; i++){
flag = 0;
scanf(???%d???, &a[i]);

if(a[i] < 2) flag = 0;
else if(a[i] == 2) flag = 1;

if(a[i]%2 == 0) flag = 0;
for(j=3; j <= a[i]/j; j+=2){
if(a[i]%j == 0) flag = 0;
}
else flag=1;

if(flag == 1) count++;
}

printf(???%d?\n???, count);
}

Compiler output:
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
    4 | main()
      | ^~~~
main.c: In function 'main':
main.c:7:7: error: expected expression before '?' token
    7 | scanf(???%d???, &n???);
      |       ^
main.c:7:20: warning: trigraph ??) ignored, use -trigraphs to enable [-Wtrigraphs]
    7 | scanf(???%d???, &n???);
main.c:11:7: error: expected expression before '?' token
   11 | scanf(???%d???, &a[i]);
      |       ^
main.c:13:4: error: 'a' undeclared (first use in this function)
   13 | if(a[i] < 2) flag = 0;
      |    ^
main.c:13:4: note: each undeclared identifier is reported only once for each function it appears in
main.c:20:1: error: 'else' without a previous 'if'
   20 | else flag=1;
      | ^~~~
main.c:25:8: error: expected expression before '?' token
   25 | printf(???%d?\n???, count);
      |        ^
main.c:25:14: error: stray '\' in program
   25 | printf(???%d?\n???, count);
      |              ^
Language: C

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

main()
{
int n, i, j, flag, count=0;
int a[10000]
scanf(???%d???, &n???);

for(i=0; i<n; i++){
flag = 0;
scanf(???%d???, &a[i]);

if(a[i] < 2) flag = 0;
else if(a[i] == 2) flag = 1;

if(a[i]%2 == 0) flag = 0;
for(j=3; j <= a[i]/j; j+=2){
if(a[i]%j == 0) flag = 0;
}
else flag=1;

if(flag == 1) count++;
}

printf(???%d?\n???, count);
}

Compiler output:
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
    4 | main()
      | ^~~~
main.c: In function 'main':
main.c:8:1: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'scanf'
    8 | scanf(???%d???, &n???);
      | ^~~~~
main.c:8:7: error: expected expression before '?' token
    8 | scanf(???%d???, &n???);
      |       ^
main.c:8:20: warning: trigraph ??) ignored, use -trigraphs to enable [-Wtrigraphs]
    8 | scanf(???%d???, &n???);
main.c:12:7: error: expected expression before '?' token
   12 | scanf(???%d???, &a[i]);
      |       ^
main.c:14:4: error: 'a' undeclared (first use in this function)
   14 | if(a[i] < 2) flag = 0;
      |    ^
main.c:14:4: note: each undeclared identifier is reported only once for each function it appears in
main.c:21:1: error: 'else' without a previous 'if'
   21 | else flag=1;
      | ^~~~
main.c:26:8: error: expected expression before '?' token
   26 | printf(???%d?\n???, count);
      |        ^
main.c:26:14: error: stray '\' in program
   26 | printf(???%d?\n???, count);
      |              ^
Language: C

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

main()
{
int n, i, j, flag, count=0;
int a[10000];
scanf(???%d???, &n???);

for(i=0; i<n; i++){
flag = 0;
scanf(???%d???, &a[i]);

if(a[i] < 2) flag = 0;
else if(a[i] == 2) flag = 1;

if(a[i]%2 == 0) flag = 0;
for(j=3; j <= a[i]/j; j+=2){
if(a[i]%j == 0) flag = 0;
}
else flag=1;

if(flag == 1) count++;
}

printf(???%d?\n???, count);
}

Compiler output:
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
    4 | main()
      | ^~~~
main.c: In function 'main':
main.c:8:7: error: expected expression before '?' token
    8 | scanf(???%d???, &n???);
      |       ^
main.c:8:20: warning: trigraph ??) ignored, use -trigraphs to enable [-Wtrigraphs]
    8 | scanf(???%d???, &n???);
main.c:12:7: error: expected expression before '?' token
   12 | scanf(???%d???, &a[i]);
      |       ^
main.c:21:1: error: 'else' without a previous 'if'
   21 | else flag=1;
      | ^~~~
main.c:26:8: error: expected expression before '?' token
   26 | printf(???%d?\n???, count);
      |        ^
main.c:26:14: error: stray '\' in program
   26 | printf(???%d?\n???, count);
      |              ^
Language: C

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

main()
{
int n, i, j, flag, count=0;
int a[10000];
scanf(???%d???, &n);

for(i=0; i<n; i++){
flag = 0;
scanf(???%d???, &a[i]);

if(a[i] < 2) flag = 0;
else if(a[i] == 2) flag = 1;

if(a[i]%2 == 0) flag = 0;
for(j=3; j <= a[i]/j; j+=2){
if(a[i]%j == 0) flag = 0;
}
else flag=1;

if(flag == 1) count++;
}

printf(???%d?\n???, count);
}

Compiler output:
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
    4 | main()
      | ^~~~
main.c: In function 'main':
main.c:8:7: error: expected expression before '?' token
    8 | scanf(???%d???, &n);
      |       ^
main.c:12:7: error: expected expression before '?' token
   12 | scanf(???%d???, &a[i]);
      |       ^
main.c:21:1: error: 'else' without a previous 'if'
   21 | else flag=1;
      | ^~~~
main.c:26:8: error: expected expression before '?' token
   26 | printf(???%d?\n???, count);
      |        ^
main.c:26:14: error: stray '\' in program
   26 | printf(???%d?\n???, count);
      |              ^
Language: C

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

main()
{
int n, i, j, flag, count=0;
int a[10000];
scanf(???%d???, &n);

for(i=0; i<n; i++){
flag = 0;
scanf(???%d???, &a[i]);

if(a[i] < 2) flag = 0;
else if(a[i] == 2) flag = 1;

if(a[i]%2 == 0) flag = 0;
else if{
for(j=3; j <= a[i]/j; j+=2){
if(a[i]%j == 0) flag = 0;
}
}
else flag=1;

if(flag == 1) count++;
}

printf(???%d?\n???, count);
}

Compiler output:
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
    4 | main()
      | ^~~~
main.c: In function 'main':
main.c:8:7: error: expected expression before '?' token
    8 | scanf(???%d???, &n);
      |       ^
main.c:12:7: error: expected expression before '?' token
   12 | scanf(???%d???, &a[i]);
      |       ^
main.c:18:8: error: expected '(' before '{' token
   18 | else if{
      |        ^
      |        (
main.c:28:8: error: expected expression before '?' token
   28 | printf(???%d?\n???, count);
      |        ^
main.c:28:14: error: stray '\' in program
   28 | printf(???%d?\n???, count);
      |              ^
Language: C

#include<stdio.h>
#define N 10000


main(){

  int n,i,k,prime=0,count=0;
  int m[N];

  scanf("%d",&n);

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

  for(i=0;i<n;i++){
    for(k=1;k<m[i]+1;k++)if(m[i]%k == 0)count++;
    if(count == 2)prime++;
    count=0;
  }
		       
  printf("%d\n",prime);

retuen0;
}

Compiler output:
main.c:5:1: error: return type defaults to 'int' [-Wimplicit-int]
    5 | main(){
      | ^~~~
main.c: In function 'main':
main.c:22:1: error: 'retuen0' undeclared (first use in this function)
   22 | retuen0;
      | ^~~~~~~
main.c:22:1: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>

int main(void){
    int n, num;
    int i;
    int count = 0;
    
    scanf("%d", &n);
    for (i=0; i <= n-1; i++){
        scanf("%d", &num);
        //?´???°:1
        if (is_prime(num)==1){
            count++; 
        }
        //printf("num:%d\n",num);
        //printf("is_prime:%d\n",is_prime(num));
    } 

    printf("%d\n", count);
    return 0;
}

//?´???°:1, ?????????:0
int is_prime(int number){
    int is = 1;
    for (int i=2; i <=number-1 ; i++){
        if(number%i==0){
            is = 0;
            break;
        }
    }
    return is; 
}

Compiler output:
main.c: In function 'main':
main.c:12:13: error: implicit declaration of function 'is_prime' [-Wimplicit-function-declaration]
   12 |         if (is_prime(num)==1){
      |             ^~~~~~~~
Language: C

#include <stdio.h>

int main(void){
    int n, num;
    int i;
    int count = 0;
    
    scanf("%d", &n);
    for (i=0; i <= n-1; i++){
        scanf("%d", &num);

        if (is_prime(num)==1){
            count++; 
        }

    } 

    printf("%d\n", count);
    return 0;
}

int is_prime(int number){
    int is = 1;
    for (int i=2; i <=number-1 ; i++){
        if(number%i==0){
            is = 0;
            break;
        }
    }
    return is; 
}

Compiler output:
main.c: In function 'main':
main.c:12:13: error: implicit declaration of function 'is_prime' [-Wimplicit-function-declaration]
   12 |         if (is_prime(num)==1){
      |             ^~~~~~~~
Language: C

#include <stdio.h>

int main(void){
    int n, num;
    int i;
    int count = 0;
    
    scanf("%d", &n);
    for (i=0; i <= n-1; i++){
        scanf("%d", &num);
        //?´???°:1
        if (is_prime(num)==1){
            count++; 
        }
        //printf("num:%d\n",num);
        //printf("is_prime:%d\n",is_prime(num));
    } 

    printf("%d\n", count);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:12:13: error: implicit declaration of function 'is_prime' [-Wimplicit-function-declaration]
   12 |         if (is_prime(num)==1){
      |             ^~~~~~~~
Language: C

#include <stdio.h>

int main(void){
    int n, num;
    int i,j;
    int count = 0;
    int is_prime;
    
    scanf("%d", &n);
    for (i=0; i <= n-1; i++){
        scanf("%d", &num);
        is_prime = 1;
        
        for (j=2; j <=num-1 ; j++){
            if(num%j==0){
                is_prime= 0;
                break;
            }
        }
        
        if (is_prime==1){
            count++; 
        }
    } 
    printf("%d\n", count);
    return 0;

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

#include<stdio.h>
#include<string.h>
#include<math.h>
#define anD &&
#define oR ||
#define max(a,b) (((a)>(b))?(a):(b))
#define min(a,b) (((a)<(b))?(a):(b))
#define rep(i,n) for((i)=0;(i)<(n);(i)++)

int is_prime( long long p) {
	int hantei,i;
	if (p == 1) {
		return 0;
	}
	else if (p == 2) {
		return 1;
	}
	else {
		for (i = 2; i <= sqrt(p) i++) {
			if (p%i == 0) return 0;
		}
		return 1;
	}
}

int main() {
	int n, i;
	int sum = 0;
	long long x;
	scanf("%d", &n);
	for (i = 0; i < n; i++) {

		scanf("%lld", &x);
		sum += is_prime(x);
	}

	printf("%d\n", sum);
	return 0;
}

Compiler output:
main.c: In function 'is_prime':
main.c:19:41: error: expected ';' before 'i'
   19 |                 for (i = 2; i <= sqrt(p) i++) {
      |                                         ^~
      |                                         ;
Language: C

#include "stdafx.h"


void main(int argc, _TCHAR* argv[])
{
	int N = 0;
	//printf("INPUT: ");
	scanf_s("%d", &N);
	int prime_n = 0;
	for (int i = 0; i < N; i++){
		int n = 0;
		scanf_s("%d", &n);
		int isPrime = 1;
//		printf("%d  ", n);
		for (int j = 2; j < n/j; j++){
//			printf("%d", j);
			if (n%j == 0){
				isPrime = 0;
				break;
			}
		}
		if (isPrime){ prime_n++; }
	}
	//printf("result");
	printf("%d", prime_n);

	//getchar();
	//getchar();

}

Compiler output:
main.c:1:10: fatal error: stdafx.h: No such file or directory
    1 | #include "stdafx.h"
      |          ^~~~~~~~~~
compilation terminated.
Language: C

#include "stdio.h"


void main(int argc, _TCHAR* argv[])
{
	int N = 0;
	//printf("INPUT: ");
	scanf_s("%d", &N);
	int prime_n = 0;
	for (int i = 0; i < N; i++){
		int n = 0;
		scanf_s("%d", &n);
		int isPrime = 1;
//		printf("%d  ", n);
		for (int j = 2; j < n/j; j++){
//			printf("%d", j);
			if (n%j == 0){
				isPrime = 0;
				break;
			}
		}
		if (isPrime){ prime_n++; }
	}
	//printf("result");
	printf("%d", prime_n);

	//getchar();
	//getchar();

}

Compiler output:
main.c:4:21: error: unknown type name '_TCHAR'
    4 | void main(int argc, _TCHAR* argv[])
      |                     ^~~~~~
Language: C

#include "stdio.h"


void main()
{
	int N = 0;
	//printf("INPUT: ");
	scanf_s("%d", &N);
	int prime_n = 0;
	for (int i = 0; i < N; i++){
		int n = 0;
		scanf_s("%d", &n);
		int isPrime = 1;
//		printf("%d  ", n);
		for (int j = 2; j < n/j; j++){
//			printf("%d", j);
			if (n%j == 0){
				isPrime = 0;
				break;
			}
		}
		if (isPrime){ prime_n++; }
	}
	//printf("result");
	printf("%d", prime_n);

	//getchar();
	//getchar();

}

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

#include <stdio.h>
 
int main(int argc, char** argv){
    int n,v;
    int i;
    int cnt;
 
    // Input
    scanf("%d",&n);
 
    // Solve
    cnt = 0;
    while(d-- > 0){
        // Input
        scanf("%d",&v);
        // Check
        for(i=2;i<n;i++){
            if( n % i == 0 ){
                cnt++;
                break;
            }
        }
    }

    // Output
    printf("%d\n",cnt);
 
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:13:11: error: 'd' undeclared (first use in this function)
   13 |     while(d-- > 0){
      |           ^
main.c:13:11: note: each undeclared identifier is reported only once for each function it appears in
main.c:15:20: error: stray '\36' in program
   15 |         scanf("%d",<U+001E>&v);
      |                    ^~~~~~~~
Language: C

#include <stdio.h>
 
int main(int argc, char** argv){
    int n,v;
    int i;
    int cnt;
 
    // Input
    scanf("%d",&n);
 
    // Solve
    cnt = 0;
    while(n-- > 0){
        // Input
        scanf("%d",&v);
        // Check
        for(i=2;i<n;i++){
            if( n % i == 0 ){
                cnt++;
                break;
            }
        }
    }

    // Output
    printf("%d\n",cnt);
 
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:15:20: error: stray '\36' in program
   15 |         scanf("%d",<U+001E>&v);
      |                    ^~~~~~~~
Language: C

#include <stdio.h>
 
int main(int argc, char** argv){
    int n,v;
    int i;
    int cnt;
 
    // Input
    scanf("%d",&n);
 
    // Solve
    cnt = 0;
    while(n-- > 0){
        // Input
        scanf("%d",&v);
        // Check
        for(i=2;i<v;i++){
            if( v % i == 0 ){
                cnt++;
                break;
            }
        }
    }

    // Output
    printf("%d\n",cnt);
 
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:15:20: error: stray '\36' in program
   15 |         scanf("%d",<U+001E>&v);
      |                    ^~~~~~~~
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,t,count=0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a[i]);
    }
    for(i = 0;i < n;i++){
      sosu(a[i]); 
      if (t == 1)
        count += 1;
    }
   
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    int t = 0;
    if(a < 2){
       return t;
    }
    else if(a == 2){
       t = 1; 
       return t;
    }
    for(i = 3; i < a; i++){
        if (a%i == 0)
           t = 1;
    }
    return t;
}






           

Compiler output:
main.c: In function 'main':
main.c:8:20: error: 'a' undeclared (first use in this function)
    8 |        scanf("%d",&a[i]);
      |                    ^
main.c:8:20: note: each undeclared identifier is reported only once for each function it appears in
main.c:11:7: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   11 |       sosu(a[i]);
      |       ^~~~
main.c: In function 'sosu':
main.c:29:9: error: 'i' undeclared (first use in this function)
   29 |     for(i = 3; i < a; i++){
      |         ^
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,t;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a[i]);
    }
    for(i = 0;i < n;i++){
      sosu(a[i]); 
      if (t == 1)
        count += 1;
    }
   
    printf("%d\n",count);
    return 0;
}

double sosu(double a){
    int t = 0;
    if(a < 2){
       return t;
    }
    else if(a == 2){
       t = 1; 
       return t;
    }
    for(i = 3; i < a; i++){
        if (a%i == 0)
           t = 1;
    }
    return t;
}






           

Compiler output:
main.c: In function 'main':
main.c:9:20: error: 'a' undeclared (first use in this function)
    9 |        scanf("%d",&a[i]);
      |                    ^
main.c:9:20: note: each undeclared identifier is reported only once for each function it appears in
main.c:12:7: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   12 |       sosu(a[i]);
      |       ^~~~
main.c: At top level:
main.c:21:8: error: conflicting types for 'sosu'; have 'double(double)'
   21 | double sosu(double a){
      |        ^~~~
main.c:12:7: note: previous implicit declaration of 'sosu' with type 'int()'
   12 |       sosu(a[i]);
      |       ^~~~
main.c: In function 'sosu':
main.c:30:9: error: 'i' undeclared (first use in this function)
   30 |     for(i = 3; i < a; i++){
      |         ^
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a,t;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
        t= sosu(a);
       if(t==1)
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    int t = 0;
    if(a == 2)
       return 1;
    
    if(a < 2){
       return 1; 
    }
    if(a%2==0)
       return 0;
    

    for(i = 3; i < a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:12: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |         t= sosu(a);
      |            ^~~~
main.c: In function 'sosu':
main.c:31:9: error: 'i' undeclared (first use in this function)
   31 |     for(i = 3; i < a; i+=2){
      |         ^
main.c:31:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a,t;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
        t= sosu(a);
       if(t==1)
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    
    if (a <= 1) return 0;

    else if(a == 2)
       return 1;
    
    if(a%2==0)
       return 0;
    

    for(i = 3; i < a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:12: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |         t= sosu(a);
      |            ^~~~
main.c: In function 'sosu':
main.c:30:9: error: 'i' undeclared (first use in this function)
   30 |     for(i = 3; i < a; i+=2){
      |         ^
main.c:30:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a,t;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
        t= sosu(a);
       if(t==1)
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    
    if (a <= 1) return 0;

    else if(a == 2)return 1;
    
    if(a%2==0) return 0;
    

    for(i = 3; i*i < a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:12: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |         t= sosu(a);
      |            ^~~~
main.c: In function 'sosu':
main.c:28:9: error: 'i' undeclared (first use in this function)
   28 |     for(i = 3; i*i < a; i+=2){
      |         ^
main.c:28:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a,t;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
       if(sosu(a))
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    
    if (a <= 1) return 0;

    else if(a == 2)return 1;
    
    if(a%2==0) return 0;
    

    for(i = 3; i*i < a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:11: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |        if(sosu(a))
      |           ^~~~
main.c: In function 'sosu':
main.c:27:9: error: 'i' undeclared (first use in this function)
   27 |     for(i = 3; i*i < a; i+=2){
      |         ^
main.c:27:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
       if(sosu(a))
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    
    if (a <= 1) return 0;

    else if(a == 2)return 1;
    
    if(a%2==0) return 0;
    

    for(i = 3; i*i < a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:11: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |        if(sosu(a))
      |           ^~~~
main.c: In function 'sosu':
main.c:27:9: error: 'i' undeclared (first use in this function)
   27 |     for(i = 3; i*i < a; i+=2){
      |         ^
main.c:27:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(void)
{
    int i,n,a;
    int count = 0;
   
    scanf("%d", &n);
    for(i = 0; i < n; i++){
       scanf("%d",&a);
       if(sosu(a))
         count++; 
    }
       
    printf("%d\n",count);
    return 0;
}

int sosu(int a){
    
    if (a <= 1) return 0;

    else if(a == 2)return 1;
    
    if(a%2==0) return 0;
    

    for(i = 3; i*i <= a; i+=2){
        if (a%i == 0)
           return 0;
           
    }
    return 1;
}






           

Compiler output:
main.c: In function 'main':
main.c:10:11: error: implicit declaration of function 'sosu' [-Wimplicit-function-declaration]
   10 |        if(sosu(a))
      |           ^~~~
main.c: In function 'sosu':
main.c:27:9: error: 'i' undeclared (first use in this function)
   27 |     for(i = 3; i*i <= a; i+=2){
      |         ^
main.c:27:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C

int main(){
  int x,cnt=0;

  while(scanf("%d",&x)!=EOF){
    if(isprime(x)==1){
      cnt++;
    }
  }

  printf("%d\n",cnt);

  return 0;
}


int isprime(int x){
  int i;

  //2 is prime number
  if(x==2) return 1;

  //odd-numbers is not prime number;
  if(x<2 || (x%2)==0) return 0;

  i = 3;
  while(i<=sqrt(x)){
    if((x%i)==0) return 0;

    i = i + 2;
  }

  return 1;
}

Compiler output:
main.c: In function 'main':
main.c:4:9: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    4 |   while(scanf("%d",&x)!=EOF){
      |         ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | int main(){
main.c:4:9: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    4 |   while(scanf("%d",&x)!=EOF){
      |         ^~~~~
main.c:4:9: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:4:25: error: 'EOF' undeclared (first use in this function)
    4 |   while(scanf("%d",&x)!=EOF){
      |                         ^~~
main.c:4:25: note: 'EOF' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
main.c:4:25: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:8: error: implicit declaration of function 'isprime' [-Wimplicit-function-declaration]
    5 |     if(isprime(x)==1){
      |        ^~~~~~~
main.c:10:3: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   10 |   printf("%d\n",cnt);
      |   ^~~~~~
main.c:10:3: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:10:3: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:10:3: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c: In function 'isprime':
main.c:26:12: error: implicit declaration of function 'sqrt' [-Wimplicit-function-declaration]
   26 |   while(i<=sqrt(x)){
      |            ^~~~
main.c:1:1: note: include '<math.h>' or provide a declaration of 'sqrt'
  +++ |+#include <math.h>
    1 | int main(){
main.c:26:12: warning: incompatible implicit declaration of built-in function 'sqrt' [-Wbuiltin-declaration-mismatch]
   26 |   while(i<=sqrt(x)){
      |            ^~~~
main.c:26:12: note: include '<math.h>' or provide a declaration of 'sqrt'
Language: C

#include <stdio.h>

int lsPrime(int a)

int main(){
  
  int i,n,a[10000],c;
  
  scanf("%d",&n);
  for(i=0;i<n;i++) {
    scanf("%d",&a);
  }
  
  for(i=0;i<n;i++) {
    c=lsPrime(a[i]);
    if(c == 1){
      b++;
    }
  }
  
  printf("%d\n",b);
  
  return 0;
}

int lsPrime(int n) {
  int i;

  if(n<2)
    return 0;
  else if(n == 2)
    return 1;

  if(n%2 == 0)
    return 0;

  for(i=3;i<=n/i;i+=2)
    if(n%i == 0)
      return 0;
  return 1;
}

Compiler output:
main.c: In function 'lsPrime':
main.c:5:11: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
    5 | int main(){
      |           ^
main.c:26:20: error: expected '=', ',', ';', 'asm' or '__attribute__' before '{' token
   26 | int lsPrime(int n) {
      |                    ^
main.c:42: error: expected '{' at end of input
Language: C

#include <stdio.h>
int main(){
 
  int n,a[100000],i,j,count=0;
  scanf("%d",&n);
  if(n<1 || N>10000) break;
  for(i=0;i<n;i++){
    scanf("%d",&a[i]);
    if(a[i]<2 && 1000000<a[i]) break;
  }
 
  for(i=0;i<n;i++){
    if(a[i]==2) count++;
    else if(a[i]<2 || a[i]%2==0) continue;
    else {
      j=3;
      while(j<a[i]){
    if(a[i]%j==0) break;
    j=j+2;
      }
      count++;
    }
  }
  printf("%d\n",count);
 
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:13: error: 'N' undeclared (first use in this function)
    6 |   if(n<1 || N>10000) break;
      |             ^
main.c:6:13: note: each undeclared identifier is reported only once for each function it appears in
main.c:6:22: error: break statement not within loop or switch
    6 |   if(n<1 || N>10000) break;
      |                      ^~~~~
Language: C

#include<stdio.h>
#include<math.h>
#define N 10000
int primenum(int);
int main(){
  int a[N],b,i,num=0;
  scanf("%d",&b);
  for(i=0;i<b;i++){
    scanf("%d\n",&a[i]);
  }
  for(i=0;i<b;i++){
    if(primenum(a[i]))
      num++;
  }
  printf("%d\n",num);
  return0;
}

int primenum(int c){
  int j;
  if(c==2)return 1;
  if(c%2==0 || c<2)return 0;
  j=3;
  while(i<=(int)sqrt(c)){
    if(c%j==0)return 0;
    j+=2;
  }
  return 1;
}

Compiler output:
main.c: In function 'main':
main.c:16:3: error: 'return0' undeclared (first use in this function)
   16 |   return0;
      |   ^~~~~~~
main.c:16:3: note: each undeclared identifier is reported only once for each function it appears in
main.c: In function 'primenum':
main.c:24:9: error: 'i' undeclared (first use in this function)
   24 |   while(i<=(int)sqrt(c)){
      |         ^
Language: C

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

int main(){
  int i,j=3,n,x[100],count=0;

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

  for(i = 0;i < n;i++){
    if(x[i] == 2){
      count++;
      continue;
    }
    else if(x[i] < 2 || x[i] % 2 == 0){
      continue;
    }
    else{
      while(sqrt(x[i]) <= s){
	if(x[i] % j == 0){
	  continue;
	}
	j = j + 2;
      }
      count++;
      continue;
    }
  }

  printf("%d\n",count);

  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:21:27: error: 's' undeclared (first use in this function)
   21 |       while(sqrt(x[i]) <= s){
      |                           ^
main.c:21:27: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
int main(){
  int count,prime=0,num[1000];
  int i,j;

  scanf("%d",&count);

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

  for(i=0;i<count;i++){
    for(j=2;j<=num[i];j++){
      if(num[i]%j==0){
	if (j!=num[i]) break;
	
	else prime++;
	}
      }
    }
  
  printf("%d\n",num_of_prime);

  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:22:17: error: 'num_of_prime' undeclared (first use in this function)
   22 |   printf("%d\n",num_of_prime);
      |                 ^~~~~~~~~~~~
main.c:22:17: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include<stdio.h>
#include<math.h>
#define N 10000
int iprime(int);
int main(){
int n,i,array[N],count = 0,x;

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

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

for(i = 0;i < n;i++){
x = iprime(array[i]);
if(x == 1)
count++;
}

printf("%d\n",count);
  return 0;
}

 int iprime(int n){
int i = 3;
if(n == 2) return 1;
if(n < 2 || n % 2 == 0) return 0;

while (i <= sqrt(n)) {
  if(n % i == 0) return 0;
  i += 2;/* code */
}
return 1;

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

#Include<stdio.h>
#define N 10000

int main(){
  int n,num[N],i,j,count=0;

  scanf("%d",&n);

  for(i=0;i<n;i++)scanf("%d",&num[i]);

  for(i=0;i<n;i++){
    if(num[i]==2)continue;
    if(num[i]%2==0 || num[i]%5==0 || num[i]%3==0||num[i]%7==0){
      count+=1;
      continue;
    }
    for(j=3;j<num[i]/2;j+=2){
      if(num[i]%j==0){
	count+=1;
	break;
      }
    }
  }
  printf("%d\n",n-count);
  
  return 0;
}

Compiler output:
main.c:1:2: error: invalid preprocessing directive #Include; did you mean #include?
    1 | #Include<stdio.h>
      |  ^~~~~~~
      |  include
main.c: In function 'main':
main.c:7:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    7 |   scanf("%d",&n);
      |   ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | #Include<stdio.h>
main.c:7:3: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    7 |   scanf("%d",&n);
      |   ^~~~~
main.c:7:3: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:24:3: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   24 |   printf("%d\n",n-count);
      |   ^~~~~~
main.c:24:3: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:24:3: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:24:3: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: C

#include <stdio.h>
#include <math.h>
#define N 10000

int main(){
  
  int n, i, j;
  int a[N];
  int count = 0;

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

  for(i = 0; i < n; i++){

    if(a[i] == 2) count++;
    else if(a[i] % 2 == 0){
   
      for(j = 3; j <= sqrt( ; j += 2){

	  if(a[i] % j == 0){
	    count++;
	    break;
	  }

	}

    }

  }

  printf("%d\n", count);

  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:22:29: error: expected expression before ';' token
   22 |       for(j = 3; j <= sqrt( ; j += 2){
      |                             ^
main.c:22:38: error: expected ';' before '{' token
   22 |       for(j = 3; j <= sqrt( ; j += 2){
      |                                      ^
      |                                      ;
main.c:31:5: error: expected expression before '}' token
   31 |     }
      |     ^
main.c:31:5: error: expected expression before '}' token
Language: C

#include <stdio.h>
int main(void){
    int record = 0;
    int roopCount1 = 0;
    int primeCount = 0;
    int divisibleCount = 0;
    scanf("%d",&record);
    for(roopCount1 = 0; roopCount1 < record; roopCount1++){
        int number[record];
        scanf("%d",&number);
        int roopCount2 = 2;
        for(roopCount2 = 2; roopCount2 <= number; roopCount2++){
            if((number % roopCount2) == 0) {
                ++divisibleCount;
            }  
        }
        if(divisibleCount == 1) ++primeCount;
        divisibleCount = 0;
    }
    printf("%d\n",primeCount);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:12:40: warning: comparison between pointer and integer
   12 |         for(roopCount2 = 2; roopCount2 <= number; roopCount2++){
      |                                        ^~
main.c:13:24: error: invalid operands to binary % (have 'int *' and 'int')
   13 |             if((number % roopCount2) == 0) {
      |                 ~~~~~~ ^
      |                 |
      |                 int *
Language: C

scanf("%d", &number);
 
  /* ?´???°????????????????????? */
  for( i=2;i<number;++i ) {
    if( number%i==0 ) {
      flag = 1;
      break;
    }
  }
 
  /* ????????????????????? */
  if( flag==0 )
    printf("%d ????´???°??§??????\n",number);
  else
    printf("%d ????´???°??§?????????????????????\n",number);
 
  return 0;
  
#include <stdio.h>
int main(void){
    int record = 0;
    int roopCount1 = 0;
    int primeCount = 0;
    int number = 0;
    int i = 2;
    int divisibleCount = 0;

    scanf("%d",&record);
    for(roopCount1 = 0; roopCount1 < record; roopCount1++){
        scanf("%d", &number);
        for( i=2;i<number;++i ) {
            if( number%i==0 ) {
              flag = 1;
              break;
            }
        }
        if(flag == 1) ++primeCount;
        flag = 0;
    }
    printf("%d\n",primeCount);
    return 0;
}

Compiler output:
main.c:1:7: error: expected declaration specifiers or '...' before string constant
    1 | scanf("%d", &number);
      |       ^~~~
main.c:1:13: error: expected declaration specifiers or '...' before '&' token
    1 | scanf("%d", &number);
      |             ^
main.c:4:3: error: expected identifier or '(' before 'for'
    4 |   for( i=2;i<number;++i ) {
      |   ^~~
main.c:4:13: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    4 |   for( i=2;i<number;++i ) {
      |             ^
main.c:4:21: error: expected identifier or '(' before '++' token
    4 |   for( i=2;i<number;++i ) {
      |                     ^~
main.c:12:3: error: expected identifier or '(' before 'if'
   12 |   if( flag==0 )
      |   ^~
main.c:14:3: error: expected identifier or '(' before 'else'
   14 |   else
      |   ^~~~
main.c:17:3: error: expected identifier or '(' before 'return'
   17 |   return 0;
      |   ^~~~~~
main.c: In function 'main':
main.c:33:15: error: 'flag' undeclared (first use in this function)
   33 |               flag = 1;
      |               ^~~~
main.c:33:15: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
#include <math.h>
int isprime(int);
int main()
{
  int n,i,count=0,x,a;
  int array[N];
  scanf(i=0;i<N;i++)
    {
      scanf("%d",&array[i]);
    }
  for(i=0;i<n;i++)
    {
      x=array[i];
      a=isprime(x);
      if(a==1)
	{
	  count=count+1;
	}
    }
  printf("%d\n",count);
  return 0;
}
int isprime(int x){
  int i;
  if(x==2) return 1;
  else if(x<2||x%2==0) return 0;
  for(i=0;i<=sqrt(x);i++)
    {
      if(x%i==0) return 0;
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:13: error: 'N' undeclared (first use in this function)
    7 |   int array[N];
      |             ^
main.c:7:13: note: each undeclared identifier is reported only once for each function it appears in
main.c:8:12: error: expected ')' before ';' token
    8 |   scanf(i=0;i<N;i++)
      |        ~   ^
      |            )
main.c:8:10: error: passing argument 1 of 'scanf' makes pointer from integer without a cast [-Wint-conversion]
    8 |   scanf(i=0;i<N;i++)
      |         ~^~
      |          |
      |          int
In file included from main.c:1:
/usr/include/stdio.h:428:42: note: expected 'const char *' but argument is of type 'int'
  428 | extern int scanf (const char *__restrict __format, ...) __wur;
      |                   ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:8:21: error: expected ';' before '{' token
    8 |   scanf(i=0;i<N;i++)
      |                     ^
      |                     ;
    9 |     {
      |     ~
Language: C

#include<stdio.h>
int isPrime(int x){
int i;
if(x<2)return 0;
else if(x==2)return 1;
if(x%2==0)return 0;
for(i=3;i*i<=x;i+=2){
if(x%2==0)return 0;
}
return 1;
}

int main()
int n,x,i;
int cnt = 0;
scanf("%d",&n);
for(i=0;i<n;i++){
scanf("%d",&x);
if(isPrime(x))cnt++;
}
printf("%d\n",cnt);
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:15:1: error: parameter 'cnt' is initialized
   15 | int cnt = 0;
      | ^~~
main.c:16:1: error: expected declaration specifiers before 'scanf'
   16 | scanf("%d",&n);
      | ^~~~~
main.c:17:1: error: expected declaration specifiers before 'for'
   17 | for(i=0;i<n;i++){
      | ^~~
main.c:17:9: error: expected declaration specifiers before 'i'
   17 | for(i=0;i<n;i++){
      |         ^
main.c:17:13: error: expected declaration specifiers before 'i'
   17 | for(i=0;i<n;i++){
      |             ^
main.c:21:1: error: expected declaration specifiers before 'printf'
   21 | printf("%d\n",cnt);
      | ^~~~~~
main.c:22:1: error: expected declaration specifiers before 'return'
   22 | return 0;
      | ^~~~~~
main.c:23:1: error: expected declaration specifiers before '}' token
   23 | }
      | ^
main.c:15:5: error: declaration for parameter 'cnt' but no such parameter
   15 | int cnt = 0;
      |     ^~~
main.c:14:9: error: declaration for parameter 'i' but no such parameter
   14 | int n,x,i;
      |         ^
main.c:14:7: error: declaration for parameter 'x' but no such parameter
   14 | int n,x,i;
      |       ^
main.c:14:5: error: declaration for parameter 'n' but no such parameter
   14 | int n,x,i;
      |     ^
main.c:24: error: expected '{' at end of input
Language: C

#include<stdio.h>
  int isprime(int x){
  int i;
  if(x<2)return 0:
    else if(x==2)return 1;
  if(x%2==0)return 0;
  for(i=3;i*i<=x;i+=2){
    if(x%i==0)return 0;
  }
  return 1:
}
 int main(){
   int n,x,i;
   int cut = 0;
   scanf("%d",&n);
   for(i=0;i<n;i++){
     scanf("%d",&x);
     if(isPrime(x))cut++:
       }
   printf("%d\n",cnt);
   return 0;
 }

Compiler output:
main.c: In function 'isprime':
main.c:4:18: error: expected ';' before ':' token
    4 |   if(x<2)return 0:
      |                  ^
      |                  ;
main.c:10:11: error: expected ';' before ':' token
   10 |   return 1:
      |           ^
      |           ;
main.c: In function 'main':
main.c:18:9: error: implicit declaration of function 'isPrime'; did you mean 'isprime'? [-Wimplicit-function-declaration]
   18 |      if(isPrime(x))cut++:
      |         ^~~~~~~
      |         isprime
main.c:18:25: error: expected ';' before ':' token
   18 |      if(isPrime(x))cut++:
      |                         ^
      |                         ;
main.c:20:18: error: 'cnt' undeclared (first use in this function); did you mean 'cut'?
   20 |    printf("%d\n",cnt);
      |                  ^~~
      |                  cut
main.c:20:18: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main(){
  int i,j,n,a,c=0,flag=0;

  scanf("%d",&n);

  for(i=0;i<n;i++){
    scanf("%d",&a);
     
    flag=0;
    for(j=2;j<a;j++){
      if(a%j==0) {
	flag=1;
	break;
      }
    }
    if(flag==0) c++;
    }
  }

  printf("%d\n",c);
  return 0;
}

Compiler output:
main.c:21:10: error: expected declaration specifiers or '...' before string constant
   21 |   printf("%d\n",c);
      |          ^~~~~~
main.c:21:17: error: unknown type name 'c'
   21 |   printf("%d\n",c);
      |                 ^
main.c:22:3: error: expected identifier or '(' before 'return'
   22 |   return 0;
      |   ^~~~~~
main.c:23:1: error: expected identifier or '(' before '}' token
   23 | }
      | ^
Language: C

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

bool is_Prime(int m);

int main() {
	int a[10000], n, i;
	int count = 0;

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

	printf("%d\n", count);

	return 0;
}

bool is_Prime(int m) {
	int i;
	for (i = 2; i <= sqrt(m)+1; i++) {
		if (m % i == 0) {
			return false;
		}
	}
	return true;
}

Compiler output:
main.c:4:1: error: unknown type name 'bool'
    4 | bool is_Prime(int m);
      | ^~~~
main.c:3:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
    2 | #include <math.h>
  +++ |+#include <stdbool.h>
    3 | 
main.c:26:1: error: unknown type name 'bool'
   26 | bool is_Prime(int m) {
      | ^~~~
main.c:26:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c: In function 'is_Prime':
main.c:30:32: error: 'false' undeclared (first use in this function)
   30 |                         return false;
      |                                ^~~~~
main.c:30:32: note: 'false' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
main.c:30:32: note: each undeclared identifier is reported only once for each function it appears in
main.c:33:16: error: 'true' undeclared (first use in this function)
   33 |         return true;
      |                ^~~~
main.c:33:16: note: 'true' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
Language: C

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

int is_Prime(int m);

int main() {
	int a[10000], n, i;
	int count = 0;

	scanf("%d", &n);
	for (i = 0; i < n; i++) {
		scanf("%d", &a[i]);
	}
	
	for (i = 0; i < n; i++) {
		if (is_Prime(a[i])==1) {
			count++;
		}
	}

	printf("%d\n", count);

	return 0;
}

int is_Prime(int m) {
	int i;
	for (i = 2; i <= sqrt(m)+1; i++) {
		if (m % i == 0???|| m == 2) {
			return 0;
		}
	}
	return 1;
}

Compiler output:
main.c: In function 'is_Prime':
main.c:29:32: error: expected expression before '?' token
   29 |                 if (m % i == 0???|| m == 2) {
      |                                ^
Language: C

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

int N;
int A[10000];
int NN = 0;

void insertion(int a[]);
int print(int d[], int c);

int main(){

	int i = 0;
	int ab, cd; 

	scanf("%d", &N);
	for (i = 0; i < N; i++){
		scanf_s("%d",&A[i]);
	}
	//printf("%d %d", ab,cd);


	insertion(A);
	printf("%d", NN);

	return 0;

}

void insertion(int a[]){
	int v;
	int i;
	int j;
	int y = 0;

	//printf("OK");

	for (i = 0; i < N; i++){
	A:;
		if (a[i] == 2) printf("%d\n", a[i]);

		if (a[i] % 2 != 0){
			for (j = 2; j <= a[i] - 1; j++){
				if (a[i] % j == 0) goto A;
				if (j == a[i] - 1){
					NN++;
				}
			}
		}
	}
}

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

 #include<stdio.h>

int main() {
   int n,i,j,x,s=0;
   
   scanf("%d",&n);
   
   for(i=0; i<n; i++) {
      scanf("%d",&x);
      for (j=2; j<n;j j++) {
         if (x%j==0)
            break;
         if (x-1==n)
          s=s+1;
      }
   }
   printf("%d\n",s);

Compiler output:
main.c: In function 'main':
main.c:10:22: error: expected ')' before 'j'
   10 |       for (j=2; j<n;j j++) {
      |           ~          ^~
      |                      )
main.c:17:4: error: expected declaration or statement at end of input
   17 |    printf("%d\n",s);
      |    ^~~~~~
Language: C

 #include<stdio.h>

int main() {
   int n,i,j,x,s=0;
   
   scanf("%d",&n);
   
   for(i=0; i<n; i++) {
      scanf("%d",&x);
      for (j=2; j<n;j j++) {
         if (x%j==0)
            break;
         if (x-1==n)
          s=s+1;
      }
   }
   printf("%d\n",s);
  
   return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:22: error: expected ')' before 'j'
   10 |       for (j=2; j<n;j j++) {
      |           ~          ^~
      |                      )
Language: C

 #include<stdio.h>

int main() {
   int n,i,j,x,s=0;
   
   scanf("%d",&n);
   
   for(i=0; i<n; i++) {
      scanf("%d",&x);
      for (j=2; j<n j++) {
         if (x%j==0)
            break;
         if (x-1==n)
          s=s+1;
      }
   }
   printf("%d\n",s);
  
   return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:20: error: expected ';' before 'j'
   10 |       for (j=2; j<n j++) {
      |                    ^~
      |                    ;