Language: C

#include <stdio.h>
#include <stdlib.h>
#define NIL -1
struct node{
  struct node *right,*left,*parent;
  int key;
};
typedef struct node *Node;
Node root;
Node Findtree(Node u,int k){
  if(u=NIL||u->key==k) return u;
  if(u->key>k) return Findtree(u->left,k);
  else return Findtree(u->right,k);
}
void insert(int k){
  Node y=NIL;
  Node x=root;
  Node z;
  z=malloc(sizeof(struct node));
  z->key=k;
  z->left=NIL;
  z->right=NIL;
  while(x!=NIL){
    y=x;
    if(z->key<x->key) x=x->left;
    else x=x->right;
  }
  z->parent=y;
  if(y==NIL) root=z;
  else if(z->key<y->key) y->left=z;
  else y->right=z;
}
void inorder(Node x){
  if(x!=NIL){
    inorder(x->left);
    printf(" %d",x->left);
    inorder(x->right);
  }
}
void preorder(Node x){
  if(x!=NIL){
    printf(" %d",x->key);
    preorder(x->left);
    preorder(x->right);
  }
}
int main(){
  int n,i,x;
  char c[20];
  Node f;
  scanf("%d",&n);
  for(i=0;i<n;i++){
    scanf("%s",c);
    if(c[0]=='f'){
      scanf("%d",&x);
      Node f=findTree(root,x);
      if(f!=NIL) printf("yes\n");
      else printf("no\n");
    if(c[0]=='i'){
      scanf("%d",&x);
      insert(x);
    }
    else if(c[0]=='p'){
      inorder(root);
      printf("\n");
      preorder(root);
      printf("\n");
    }
  }
  return 0;
}  

Compiler output:
main.c: In function 'Findtree':
main.c:11:7: error: assignment to 'Node' {aka 'struct node *'} from 'int' makes pointer from integer without a cast [-Wint-conversion]
   11 |   if(u=NIL||u->key==k) return u;
      |       ^
main.c: In function 'insert':
main.c:3:13: error: initialization of 'Node' {aka 'struct node *'} from 'int' makes pointer from integer without a cast [-Wint-conversion]
    3 | #define NIL -1
      |             ^
main.c:16:10: note: in expansion of macro 'NIL'
   16 |   Node y=NIL;
      |          ^~~
main.c:21:10: error: assignment to 'struct node *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
   21 |   z->left=NIL;
      |          ^
main.c:22:11: error: assignment to 'struct node *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
   22 |   z->right=NIL;
      |           ^
main.c:23:10: warning: comparison between pointer and integer
   23 |   while(x!=NIL){
      |          ^~
main.c:29:7: warning: comparison between pointer and integer
   29 |   if(y==NIL) root=z;
      |       ^~
main.c: In function 'inorder':
main.c:34:7: warning: comparison between pointer and integer
   34 |   if(x!=NIL){
      |       ^~
main.c: In function 'preorder':
main.c:41:7: warning: comparison between pointer and integer
   41 |   if(x!=NIL){
      |       ^~
main.c: In function 'main':
main.c:56:14: error: implicit declaration of function 'findTree'; did you mean 'Findtree'? [-Wimplicit-function-declaration]
   56 |       Node f=findTree(root,x);
      |              ^~~~~~~~
      |              Findtree
main.c:56:14: error: initialization of 'Node' {aka 'struct node *'} from 'int' makes pointer from integer without a cast [-Wint-conversion]
main.c:57:11: warning: comparison between pointer and integer
   57 |       if(f!=NIL) printf("yes\n");
      |           ^~
main.c:71:1: error: expected declaration or statement at end of input
   71 | }
      | ^