Language: C

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


Compiler output:
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include<stdio.h>
      |        ^
main.c: In function 'main':
main.c:17:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
   17 |   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:17:3: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
   17 |   scanf("%d",&n);
      |   ^~~~~
main.c:17:3: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:22:3: error: implicit declaration of function 'countingsort' [-Wimplicit-function-declaration]
   22 |   countingsort(n,a,b,k);
      |   ^~~~~~~~~~~~
main.c:23:19: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
   23 |   for(i=1;i<n;i++)printf("%d ",b[i]);
      |                   ^~~~~~
main.c:23:19: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:23:19: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:23:19: 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]
   24 |   printf("%d\n",b[n]);
      |   ^~~~~~
main.c:24:3: note: include '<stdio.h>' or provide a declaration of 'printf'