Language: C++

// ????????¨?????????

#include<iostream>
#include<cstdio>
#include<cmath>
using namespace std;
#define MAX 30
#define NIL -1

struct Node { int parent, leftChild, rightSibling; };

Node tree[MAX];
int depth[MAX];
int height[MAX];

void preorder(root){
    printf(" %d", root);
    if (Node[root].leftChild != NIL)
    {
        preorder(Node[root].leftChild);
    }
    if (Node[root].rightSibling != NIL)
    {
        preorder(Node[root].rightSibling);
    }
}

void inorder(root){
    if (root == NIL)
    {
        return
    }
    inorder(Node[root].leftChild);
    printf("%d", root);
    inorder(Node[root].rightSibling);
}

void postorder(root){
    if (root == NIL)
    {
        return
    }
    inorder(Node[root].leftChild);
    inorder(Node[root].rightSibling);
    printf("%d", root);
}

int main(int argc, char const *argv[])
{
    int numNode;
    int id, left, right;
    cin >> numNode;

    // store the values
    for (int i = 0; i < numNode; ++i)
    {
        scanf("%d %d %d", &id, &left, &right);
        Node[id].leftChild = left;
        Node[id].rightSibling = right;
        if (left != NIL)
        {
            Node[leftChild].parent = id;
        }
        if (right != NIL)
        {
            Node[rightSibling].parent = id;
        }
    }
    // find the root
    int root;
    for (int i = 0; i < numNode; ++i)
    {
        if (Node[i].parent == NIL)
        {
            root = i;
        }
    }
    // print
    printf("Preorder\n");
    preorder(root);
    printf("\n");
    printf("Inorder\n");
    inorder(root);
    printf("\n");
    printf("Postorder\n");
    postorder(root);
    printf("\n");

    return 0;
}

Compiler output:
a.cc:16:6: error: variable or field 'preorder' declared void
   16 | void preorder(root){
      |      ^~~~~~~~
a.cc:16:15: error: 'root' was not declared in this scope
   16 | void preorder(root){
      |               ^~~~
a.cc:28:6: error: variable or field 'inorder' declared void
   28 | void inorder(root){
      |      ^~~~~~~
a.cc:28:14: error: 'root' was not declared in this scope
   28 | void inorder(root){
      |              ^~~~
a.cc:38:6: error: variable or field 'postorder' declared void
   38 | void postorder(root){
      |      ^~~~~~~~~
a.cc:38:16: error: 'root' was not declared in this scope
   38 | void postorder(root){
      |                ^~~~
a.cc: In function 'int main(int, const char**)':
a.cc:58:13: error: structured binding declaration cannot have type 'Node'
   58 |         Node[id].leftChild = left;
      |             ^~~~
a.cc:58:13: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:58:17: error: expected initializer before '.' token
   58 |         Node[id].leftChild = left;
      |                 ^
a.cc:58:17: error: expected ';' before '.' token
a.cc:59:13: error: structured binding declaration cannot have type 'Node'
   59 |         Node[id].rightSibling = right;
      |             ^~~~
a.cc:59:13: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:59:17: error: expected initializer before '.' token
   59 |         Node[id].rightSibling = right;
      |                 ^
a.cc:62:17: error: structured binding declaration cannot have type 'Node'
   62 |             Node[leftChild].parent = id;
      |                 ^~~~~~~~~~~
a.cc:62:17: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:62:28: error: expected initializer before '.' token
   62 |             Node[leftChild].parent = id;
      |                            ^
a.cc:62:28: error: expected ';' before '.' token
a.cc:66:17: error: structured binding declaration cannot have type 'Node'
   66 |             Node[rightSibling].parent = id;
      |                 ^~~~~~~~~~~~~~
a.cc:66:17: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:66:31: error: expected initializer before '.' token
   66 |             Node[rightSibling].parent = id;
      |                               ^
a.cc:66:31: error: expected ';' before '.' token
a.cc:73:17: error: expected unqualified-id before '[' token
   73 |         if (Node[i].parent == NIL)
      |                 ^
a.cc:80:5: error: 'preorder' was not declared in this scope
   80 |     preorder(root);
      |     ^~~~~~~~
a.cc:83:5: error: 'inorder' was not declared in this scope
   83 |     inorder(root);
      |     ^~~~~~~
a.cc:86:5: error: 'postorder' was not declared in this scope
   86 |     postorder(root);
      |     ^~~~~~~~~