Language: C++

#include<bits/stdc++.h>
#define ll long long int
#define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
#define REP(i,n) FOR(i,0,n)
#define REP1(i,n) FOR(i,1,n)
#define MAX 100

using namespace std;
 
struct Card { char suit, value; };
 
void bubbleSort(struct Card C[], int N) {
  REP(int i, N) {
    for (int j = N - 1; j >= i + 1; j--) {
      if (C[j].value < C[j - 1].value) {
        Card temp = C[j];
        C[j] = C[j - 1];
        C[j - 1] = temp;
      }
    }
  }
}
 
void selectionSort(struct Card C[], int N) {
  for (int i = 0; i < N; i++) {
    int minj = i;
    for (int j = i; j < N; j++) {
      if (C[j].value < C[minj].value) {
        minj = j;
      }
    }
    Card temp = C[i];
    C[i] = C[minj];
    C[minj] = temp;
  }
}
 
void print(struct Card C[], int N) {
  for (int i = 0; i < N; i++) {
    if (i > 0) cout << " ";
    cout << C[i].suit << C[i].value;
  }
  cout << endl;
}
 
bool isStable (struct Card C1[], struct Card C2[], int N) {
  for (int i = 0; i < N; i++) {
    if (C1[i].suit != C2[i].suit) {
      return false;
    }
  }
  return true;
}
   
   
int main() {
  Card C1[MAX], C2[MAX];
  int N;
   
  cin >> N;
  for (int i = 0; i < N; i++) {
    cin >> C1[i].suit >> C1[i].value;
    C2[i] = C1[i];
  }
 
  bubbleSort(C1, N);
  selectionSort(C2, N);
 
  print(C1, N);
  cout << "Stable" << endl;
  print(C2, N);
  if (isStable(C1, C2, N)) {
    cout << "Stable" << endl;
  } else {
    cout << "Not stable" << endl;
  }
 
  return 0;
}

Compiler output:
a.cc: In function 'void bubbleSort(Card*, int)':
a.cc:2:22: error: two or more data types in declaration of 'i'
    2 | #define ll long long int
      |                      ^~~
a.cc:3:24: note: in expansion of macro 'll'
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                        ^~
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~
a.cc:3:38: error: expected initializer before '<' token
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                                      ^
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~
a.cc:3:38: error: expected ';' before '<' token
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                                      ^
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~
a.cc:3:38: error: expected primary-expression before '<' token
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                                      ^
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~
a.cc:3:46: error: expected ')' before ';' token
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                       ~                      ^
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~
a.cc:3:48: error: expected initializer before '++' token
    3 | #define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
      |                                                ^~
a.cc:4:18: note: in expansion of macro 'FOR'
    4 | #define REP(i,n) FOR(i,0,n)
      |                  ^~~
a.cc:13:3: note: in expansion of macro 'REP'
   13 |   REP(int i, N) {
      |   ^~~