Language: C

#include <stdio.h>

struct DICE {
int mark[5];
};

void MoveDice(struct DICE *p,char c);

int main(){

struct DICE p;char compass;
scanf("%d %d %d %d %d %d\n",p.mark[0],p.mark[1],p.mark[2],p.mark[3],p.mark[4],p.mark[5]);
scanf("%c", &compass);
while(compass!='\n'){
MoveDice(&p,compass);
scanf("%c", &compass);
}

return 0;
}

void MoveDice(struct DICE *p,char c){
int tmp;
tmp=p.mark[1];
switch(c){
case 'W':
*p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
break;
case 'E':
*p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
break;
case 'N':
*p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
break;
case 'S':
*p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
break;
}
}

Compiler output:
main.c: In function 'MoveDice':
main.c:24:6: error: 'p' is a pointer; did you mean to use '->'?
   24 | tmp=p.mark[1];
      |      ^
      |      ->
main.c:27:1: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      | ^~~~~~~~~~~
main.c:27:13: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |             ^~~~~~~~~~~
main.c:27:25: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |                         ^~~~~~~~~~~
main.c:27:37: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |                                     ^~~~~~~~~~~
main.c:27:49: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |                                                 ^~~~~~~~~~~
main.c:27:61: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |                                                             ^~~~~~~~~~~
main.c:27:73: error: invalid type argument of unary '*' (have 'int')
   27 | *p->mark[1]=*p->mark[3];*p->mark[3]=*p->mark[6];*p->mark[6]=*p->mark[4];*p->mark[4]=tmp;
      |                                                                         ^~~~~~~~~~~
main.c:30:1: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      | ^~~~~~~~~~~
main.c:30:13: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |             ^~~~~~~~~~~
main.c:30:25: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |                         ^~~~~~~~~~~
main.c:30:37: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |                                     ^~~~~~~~~~~
main.c:30:49: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |                                                 ^~~~~~~~~~~
main.c:30:61: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |                                                             ^~~~~~~~~~~
main.c:30:73: error: invalid type argument of unary '*' (have 'int')
   30 | *p->mark[1]=*p->mark[4];*p->mark[4]=*p->mark[6];*p->mark[6]=*p->mark[3];*p->mark[3]=tmp;
      |                                                                         ^~~~~~~~~~~
main.c:33:1: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      | ^~~~~~~~~~~
main.c:33:13: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |             ^~~~~~~~~~~
main.c:33:25: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |                         ^~~~~~~~~~~
main.c:33:37: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |                                     ^~~~~~~~~~~
main.c:33:49: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |                                                 ^~~~~~~~~~~
main.c:33:61: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |                                                             ^~~~~~~~~~~
main.c:33:73: error: invalid type argument of unary '*' (have 'int')
   33 | *p->mark[1]=*p->mark[2];*p->mark[2]=*p->mark[6];*p->mark[6]=*p->mark[5];*p->mark[5]=tmp;
      |                                                                         ^~~~~~~~~~~
main.c:36:1: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      | ^~~~~~~~~~~
main.c:36:13: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |             ^~~~~~~~~~~
main.c:36:25: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |                         ^~~~~~~~~~~
main.c:36:37: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |                                     ^~~~~~~~~~~
main.c:36:49: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |                                                 ^~~~~~~~~~~
main.c:36:61: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |                                                             ^~~~~~~~~~~
main.c:36:73: error: invalid type argument of unary '*' (have 'int')
   36 | *p->mark[1]=*p->mark[5];*p->mark[5]=*p->mark[6];*p->mark[6]=*p->mark[2];*p->mark[2]=tmp;
      |                                                                         ^~~~~~~~~~~