Language: C

include<stdio.h>
#define MAX 100000
#define NUMBER 2000000000

typedef struct
{
  char mark;
  int num;
}cards;

cards c1[MAX/2+2],c2[MAX/2+2];

void merg(cards M[],int n,int left, int middle, int right)
{
  int i,j,l;
  int a,b;
  a=middle-left;
  b=right-middle;
  for(i=0;i<a;i++)c1[i]=M[left+i];
  for(i=0;i<b;i++)c2[i]=M[middle+i];
  c1[a].num=NUMBER;
  c2[b].num=NUMBER;
  i=0;
  j=0;
  for(l=left;l<right;l++)
    {
      if(c1[i].num<=c2[j].num)
        {
          M[l]=c1[i++];
        }
      else
        {
          M[l]=c2[j++];
        }
    }
}

void mergS(cards M[],int n, int left, int right)
{
  int middle;
  if(left+1<right)
    {
      middle=(left+right)/2;
      mergS(M,n,left,middle);
      mergS(M,n,middle,right);
      merg(M,n,left,middle,right);
    }
}

int part(cards M[], int n,int posi,int las)
{
  int i,j;
  cards A,B;
  B=M[las];i=posi-1;
  for(j=posi;j<las;j++)
    {
      if(M[j].num<=B.num)
        {
          i++;
          A=M[i];
          M[i]=M[j];
          M[j]=A;
        }
    }
  A=M[i+1];
  M[i+1]=M[las];
  M[las]=A;
  return i+1;
}

void quickS(cards M[],int n, int posi,int las)
{
  int k;
  if(posi<las)
    {
      k=part(M,n,posi,las);
      quickS(M,n,posi,k-1);
      quickS(M,n,k+1,las);
    }
}
int main()
{
  int i,cnt,va;
  cards S[MAX],T[MAX];
  char MR[10];
  int t=1;
  scanf("%d",&cnt);
  for(i=0;i<cnt;i++)
    {
      scanf("%s %d",MR,&va);
      S[i].mark=MR[0];
      T[i].mark=MR[0];
      S[i].num=va;
      T[i].num=va;
    }
  mergS(S,cnt,0,cnt);
  quickS(T,cnt,0,cnt-1);

  for(i=0;i<cnt;i++)
    {
      if(S[i].mark!=T[i].mark)t=0;
    }
  if(t==1)printf("Stable\n");
  else printf("Not stable\n");
  for(i=0;i<cnt;i++)
    {
      printf("%c %d\n",T[i].mark,T[i].num);
    }
  return 0;
}

Compiler output:
main.c:1:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    1 | include<stdio.h>
      |        ^
main.c:9:2: warning: data definition has no type or storage class
    9 | }cards;
      |  ^~~~~
main.c:9:2: error: type defaults to 'int' in declaration of 'cards' [-Wimplicit-int]
main.c:11:1: error: unknown type name 'cards'
   11 | cards c1[MAX/2+2],c2[MAX/2+2];
      | ^~~~~
main.c:13:11: error: expected declaration specifiers or '...' before 'cards'
   13 | void merg(cards M[],int n,int left, int middle, int right)
      |           ^~~~~
main.c:38:12: error: expected declaration specifiers or '...' before 'cards'
   38 | void mergS(cards M[],int n, int left, int right)
      |            ^~~~~
main.c:50:10: error: expected declaration specifiers or '...' before 'cards'
   50 | int part(cards M[], int n,int posi,int las)
      |          ^~~~~
main.c:71:13: error: expected declaration specifiers or '...' before 'cards'
   71 | void quickS(cards M[],int n, int posi,int las)
      |             ^~~~~
main.c: In function 'main':
main.c:84:8: error: expected ';' before 'S'
   84 |   cards S[MAX],T[MAX];
      |        ^~
      |        ;
main.c:87:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
   87 |   scanf("%d",&cnt);
      |   ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | include<stdio.h>
main.c:87:3: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
   87 |   scanf("%d",&cnt);
      |   ^~~~~
main.c:87:3: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:91:7: error: 'S' undeclared (first use in this function)
   91 |       S[i].mark=MR[0];
      |       ^
main.c:91:7: note: each undeclared identifier is reported only once for each function it appears in
main.c:92:7: error: 'T' undeclared (first use in this function)
   92 |       T[i].mark=MR[0];
      |       ^
main.c:96:3: error: implicit declaration of function 'mergS' [-Wimplicit-function-declaration]
   96 |   mergS(S,cnt,0,cnt);
      |   ^~~~~
main.c:97:3: error: implicit declaration of function 'quickS' [-Wimplicit-function-declaration]
   97 |   quickS(T,cnt,0,cnt-1);
      |   ^~~~~~
main.c:103:11: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
  103 |   if(t==1)printf("Stable\n");
      |           ^~~~~~
main.c:103:11: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:103:11: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:103:11: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:104:8: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
  104 |   else printf("Not stable\n");
      |        ^~~~~~
main.c:104:8: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:107:7: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
  107 |       printf("%c %d\n",T[i].mark,T[i].num);
      |       ^~~~~~
main.c:107:7: note: include '<stdio.h>' or provide a declaration of 'printf'