Language: C++

#include <iostream>
using namespace std;

void QuickSort(int A[], int p, int r){  //S:?????? B:?§???? T:??????
  int x = A[r];
  int i = p-1;
  for(int j=p,j<r,j++){
    if(A[j]<=x){
      i=i+1;
      int num1=A[i];
      A[i]=A[j];
      A[j]=num;
    }
  }
  int num2=A[i+1];
  A[i+1]=A[r];
  A[r]=num2;

  int q = i+1;

  for(int k=0,k<r,k++){
    if(A[k] != q){
      cout<<A[k]<<" ";
    }else if(A[K] = q){
      cout<<"["<<A[k]<<"]"<<" ";
    }
  }

  cout<<endl;

  return i+1;
}

int main{
  int length;
  int array[length];
  cin>>length;
  for(int i = 0,i<length,i++){
    cin>>array[i];
  }

  QuickSort(array[],array[0],array[length]);

  return 0;
}

Compiler output:
a.cc: In function 'void QuickSort(int*, int, int)':
a.cc:7:16: error: expected ';' before '<' token
    7 |   for(int j=p,j<r,j++){
      |                ^
      |                ;
a.cc:7:16: error: expected primary-expression before '<' token
a.cc:7:22: error: expected ';' before ')' token
    7 |   for(int j=p,j<r,j++){
      |                      ^
      |                      ;
a.cc:12:12: error: 'num' was not declared in this scope; did you mean 'num1'?
   12 |       A[j]=num;
      |            ^~~
      |            num1
a.cc:21:16: error: expected ';' before '<' token
   21 |   for(int k=0,k<r,k++){
      |                ^
      |                ;
a.cc:21:16: error: expected primary-expression before '<' token
a.cc:21:22: error: expected ';' before ')' token
   21 |   for(int k=0,k<r,k++){
      |                      ^
      |                      ;
a.cc:24:16: error: 'K' was not declared in this scope
   24 |     }else if(A[K] = q){
      |                ^
a.cc:31:11: error: return-statement with a value, in function returning 'void' [-fpermissive]
   31 |   return i+1;
      |          ~^~
a.cc: At global scope:
a.cc:34:5: error: cannot declare '::main' to be a global variable
   34 | int main{
      |     ^~~~
a.cc:35:3: error: expected primary-expression before 'int'
   35 |   int length;
      |   ^~~
a.cc:35:3: error: expected '}' before 'int'
a.cc:34:9: note: to match this '{'
   34 | int main{
      |         ^
a.cc:36:13: error: 'length' was not declared in this scope
   36 |   int array[length];
      |             ^~~~~~
a.cc:37:3: error: 'cin' does not name a type
   37 |   cin>>length;
      |   ^~~
a.cc:38:3: error: expected unqualified-id before 'for'
   38 |   for(int i = 0,i<length,i++){
      |   ^~~
a.cc:42:19: error: creating array of template placeholder type 'array<...auto...>'
   42 |   QuickSort(array[],array[0],array[length]);
      |                   ^
a.cc:42:28: error: creating array of template placeholder type 'array<...auto...>'
   42 |   QuickSort(array[],array[0],array[length]);
      |                            ^
a.cc:42:36: error: 'length' was not declared in this scope
   42 |   QuickSort(array[],array[0],array[length]);
      |                                    ^~~~~~
a.cc:42:44: error: expected constructor, destructor, or type conversion before ';' token
   42 |   QuickSort(array[],array[0],array[length]);
      |                                            ^
a.cc:44:3: error: expected unqualified-id before 'return'
   44 |   return 0;
      |   ^~~~~~
a.cc:45:1: error: expected declaration before '}' token
   45 | }
      | ^