Language: C

#include <stdio.h>
#include <string.h>


int main(void)
{
    int x,n,i,j,top,dice[105][10],dice2[10];

    scanf("%d",&n);
    for(j=0;j<n;j++){
        for(i=0;i<6;i++){
            scanf("%d",&dice[j][i]);
        }
    }
    
    for(j=0;j<n;j++){
    for(i=0;i<8;i++){
        if(memcmp(dice[0],dice[j],sizeof(dice))==0)break;
        if(dice[0]==dice[j]){
            for(x=0;x<4;x++){
                top=dice2[1];
                dice2[j][1]=dice2[j][2];
                dice2[j][2]=dice2[j][4];
                dice2[j][4]=dice2[j][3];
                dice2[j][3]=top;
                if(memcmp(dice[0],dice[j],sizeof(dice))!=0) goto OUT;
            }
        }
        if(i<4){
                top=dice2[j][0];
                dice2[j][0]=dice2[j][1];
                dice2[j][1]=dice2[j][5];
                dice2[j][5]=dice2[j][4];
                dice2[j][4]=top;
        }else{
                top=dice2[j][0];
                dice2[j][0]=dice2[j][2];
                dice2[j][2]=dice2[j][5];
                dice2[j][5]=dice2[j][3];
                dice2[j][3]=top;
        }
    }
    }
    OUT:

    if(memcmp(dice[0],dice[j],sizeof(dice))!=0){
        printf("Yes\n");
    }else{
        printf("No\n");
    }
    return 0;
}




Compiler output:
main.c: In function 'main':
main.c:22:25: error: subscripted value is neither array nor pointer nor vector
   22 |                 dice2[j][1]=dice2[j][2];
      |                         ^
main.c:22:37: error: subscripted value is neither array nor pointer nor vector
   22 |                 dice2[j][1]=dice2[j][2];
      |                                     ^
main.c:23:25: error: subscripted value is neither array nor pointer nor vector
   23 |                 dice2[j][2]=dice2[j][4];
      |                         ^
main.c:23:37: error: subscripted value is neither array nor pointer nor vector
   23 |                 dice2[j][2]=dice2[j][4];
      |                                     ^
main.c:24:25: error: subscripted value is neither array nor pointer nor vector
   24 |                 dice2[j][4]=dice2[j][3];
      |                         ^
main.c:24:37: error: subscripted value is neither array nor pointer nor vector
   24 |                 dice2[j][4]=dice2[j][3];
      |                                     ^
main.c:25:25: error: subscripted value is neither array nor pointer nor vector
   25 |                 dice2[j][3]=top;
      |                         ^
main.c:30:29: error: subscripted value is neither array nor pointer nor vector
   30 |                 top=dice2[j][0];
      |                             ^
main.c:31:25: error: subscripted value is neither array nor pointer nor vector
   31 |                 dice2[j][0]=dice2[j][1];
      |                         ^
main.c:31:37: error: subscripted value is neither array nor pointer nor vector
   31 |                 dice2[j][0]=dice2[j][1];
      |                                     ^
main.c:32:25: error: subscripted value is neither array nor pointer nor vector
   32 |                 dice2[j][1]=dice2[j][5];
      |                         ^
main.c:32:37: error: subscripted value is neither array nor pointer nor vector
   32 |                 dice2[j][1]=dice2[j][5];
      |                                     ^
main.c:33:25: error: subscripted value is neither array nor pointer nor vector
   33 |                 dice2[j][5]=dice2[j][4];
      |                         ^
main.c:33:37: error: subscripted value is neither array nor pointer nor vector
   33 |                 dice2[j][5]=dice2[j][4];
      |                                     ^
main.c:34:25: error: subscripted value is neither array nor pointer nor vector
   34 |                 dice2[j][4]=top;
      |                         ^
main.c:36:29: error: subscripted value is neither array nor pointer nor vector
   36 |                 top=dice2[j][0];
      |                             ^
main.c:37:25: error: subscripted value is neither array nor pointer nor vector
   37 |                 dice2[j][0]=dice2[j][2];
      |                         ^
main.c:37:37: error: subscripted value is neither array nor pointer nor vector
   37 |                 dice2[j][0]=dice2[j][2];
      |                                     ^
main.c:38:25: error: subscripted value is neither array nor pointer nor vector
   38 |                 dice2[j][2]=dice2[j][5];
      |                         ^
main.c:38:37: error: subscripted value is neither array nor pointer nor vector
   38 |                 dice2[j][2]=dice2[j][5];
      |                                     ^
main.c:39:25: error: subscripted value is neither array nor pointer nor vector
   39 |                 dice2[j][5]=dice2[j][3];
      |                         ^
main.c:39:37: error: subscripted value is neither array nor pointer nor vector
   39 |                 dice2[j][5]=dice2[j][3];
      |                                     ^
main.c:40:25: error: subscripted value is neither array nor pointer nor vector
   40 |                 dice2[j][3]=top;
      |                         ^