Language: C

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

int main(void)
{
	int i = 0, j = 0, n, count = 0;
	int seisu[20];
	char str[20];
	char tok[20][20];
	scanf("%d", &n);
	while (getchar() != '\n');
	fgets(str, sizeof(str), stdin);

	char *p = str;


	strtok(p, " ");
	strcpy(tok[i], p);

	while (1) {
		i++;
		p = strtok(NULL, " ");
		if (p == NULL)
			break;
		strcpy(tok[i], p);
	}

	for (i = 0; i < n; i++) {
		seisu[i] = atoi(tok[i]);
	}


	int irekae;

	for (i = 0; i < n; i++) {
		for (j = n - 1; 0 < j; j--) {
			if (seisu[j] < seisu[j - 1]) {
				irekae = seisu[j];
				seisu[j] = seisu[j - 1];
				seisu[j - 1] = irekae;
				count++;
			}
		}
	}

	for (i = 0; i < n; i++)
		printf("%d ", seisu[i]);

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

	return 0;

}
		if (p == NULL)
			break;
		strcpy(tok[i], p);
	}

	for (i = 0; i < n; i++) {
		seisu[i] = atoi(tok[i]);
	}


	int irekae;

	for (i = 0; i < n; i++) {
		for (j = n - 1; 0 < j; j--) {
			if (seisu[j] < seisu[j - 1]) {
				irekae = seisu[j];
				seisu[j] = seisu[j - 1];
				seisu[j - 1] = irekae;
				count++;
			}
		}
	}

	for (i = 0; i < n; i++)
		printf("%d ", seisu[i]);

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

	return 0;

}


Compiler output:
main.c:55:17: error: expected identifier or '(' before 'if'
   55 |                 if (p == NULL)
      |                 ^~
main.c:57:24: error: unknown type name 'tok'
   57 |                 strcpy(tok[i], p);
      |                        ^~~
main.c:57:32: error: unknown type name 'p'
   57 |                 strcpy(tok[i], p);
      |                                ^
main.c:58:9: error: expected identifier or '(' before '}' token
   58 |         }
      |         ^
main.c:60:9: error: expected identifier or '(' before 'for'
   60 |         for (i = 0; i < n; i++) {
      |         ^~~
main.c:60:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   60 |         for (i = 0; i < n; i++) {
      |                       ^
main.c:60:29: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   60 |         for (i = 0; i < n; i++) {
      |                             ^~
main.c:67:9: error: expected identifier or '(' before 'for'
   67 |         for (i = 0; i < n; i++) {
      |         ^~~
main.c:67:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   67 |         for (i = 0; i < n; i++) {
      |                       ^
main.c:67:29: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   67 |         for (i = 0; i < n; i++) {
      |                             ^~
main.c:78:9: error: expected identifier or '(' before 'for'
   78 |         for (i = 0; i < n; i++)
      |         ^~~
main.c:78:23: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
   78 |         for (i = 0; i < n; i++)
      |                       ^
main.c:78:29: error: expected '=', ',', ';', 'asm' or '__attribute__' before '++' token
   78 |         for (i = 0; i < n; i++)
      |                             ^~
main.c:81:16: error: expected declaration specifiers or '...' before string constant
   81 |         printf("\n%d\n", count);
      |                ^~~~~~~~
main.c:81:26: error: unknown type name 'count'
   81 |         printf("\n%d\n", count);
      |                          ^~~~~
main.c:83:9: error: expected identifier or '(' before 'return'
   83 |         return 0;
      |         ^~~~~~
main.c:85:1: error: expected identifier or '(' before '}' token
   85 | }
      | ^