Language: C++

#include <iostream>
using namespace std;
class Dice{
public:
	int num[6],t;//t=top
	void North(){
		/*
		dice.num[0] = ???
		dice.num[1] = ???
		dice.num[2] = ???
		dice.num[3] = ???
		dice.num[4] = ???
		dice.num[5] = ???*/
		
		t = num[0];
		num[0] = num[1];//??????1?????¨???
		num[1] = num[5];//??????2?????¨???
		num[5] = num[4];//??????6?????¨???
		num[4] = t;//??????5?????¨???
		}

	void East(){
		t = num[0];
		num[0] = num[3];//??????1?????¨???
		num[3] = num[5];//??????4?????¨???
		num[5] = num[2];//??????6?????¨???
		num[2] = t;//??????3?????¨???
		}

	void West(){
		t = num[0];
		num[0] = num[2];//??????1?????¨???
		num[2] = num[5];//??????5?????¨???
		num[5] = num[3];//??????6?????¨???
		num[3] = t;//??????2?????¨???
		}
		
	void South(){
		t = num[0];
		num[0] = num[4];//??????1?????¨???
		num[4] = num[5];//??????3?????¨???
		num[5] = num[1];//??????6?????¨???
		num[1] = t;//??????3?????¨???
		}
	
	void Rotation(){//?????¢??????????????§?????¢???????????¨???
		t = num[1];
		num[1] = num[2];//?????¢???2?????¨???
		num[2] = num[4];//?????¢???3?????¨???
		num[4] = num[3];//?????¢???5?????¨???
		num[3] = t;//?????¢???4?????¨???
		}
};

int main()
{
	
	Dice d[100];//2<=n<=100
	int n;
	
	cin >>n;
/*	
	for(int i=0; i<n; i++){//dice
		cin >> d[i].num[0] >> d[i].num[1] >> d[i].num[2] >> d[i].num[3] >> d[i].num[4] >> d[i].num[5];
	}
	
	for(int i=0; i<n; i++){
		for(int j=0; j<n; j++){
			if(i == j);continue;
			
			for(int k=0; k<6; k++){//dice?????°???
				if (k == 4){
					d[i].East();
				}
				if(k == 5){//dice?????°?????¨????????????
					d[i].East();
					d[i].East();
				}
				
				for(int l=0; l<4; l++){//dice?????°??????4???????????????????????????Rotation
					d[i].Rotation();
					//?????????????????????????????´??????No
					if( d[i].num[0] == d[j].num[0] &&
						d[i].num[1] == d[j].num[1] &&
						d[i].num[2] == d[j].num[2] &&
						d[i].num[3] == d[j].num[3] &&
						d[i].num[4] == d[j].num[4] &&
						d[i].num[5] == d[j].num[5] )
					{cout << "No" << endl;
						return 0;
					}
					
				}
			}
		}
	}
	cout << "Yes" << endl;
	return 0;
}



int main(){
    Dice d[100];
    int n;
     
    cin>>n;*/
    for(int i=0; i<n; i++){
        cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
    }
    for(int i=0; i<n; i++){
        for(int j=0; j<n; j++){
            if(j==i)continue;
            for(int k=0; k<6; k++){
                if(k==4){
                    d[i].East();
                }
                if(k==5){
                d[i].East();
                d[i].East();
                }
                for(int l=0; l<4; l++){
                    d[i].Rotation();
                    if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
                       d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
                        cout<<"No"<<endl;
                        return 0;
                    }
                }
            }
             
        }
         
    }
    cout<<"Yes"<<endl;
    return 0;

Compiler output:
a.cc: In function 'int main()':
a.cc:109:19: error: 'class Dice' has no member named 'n1'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                   ^~
a.cc:109:28: error: 'class Dice' has no member named 'n2'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                            ^~
a.cc:109:37: error: 'class Dice' has no member named 'n3'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                                     ^~
a.cc:109:46: error: 'class Dice' has no member named 'n4'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                                              ^~
a.cc:109:55: error: 'class Dice' has no member named 'n5'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                                                       ^~
a.cc:109:64: error: 'class Dice' has no member named 'n6'
  109 |         cin>>d[i].n1>>d[i].n2>>d[i].n3>>d[i].n4>>d[i].n5>>d[i].n6;
      |                                                                ^~
a.cc:124:29: error: 'class Dice' has no member named 'n1'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                             ^~
a.cc:124:38: error: 'class Dice' has no member named 'n1'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                                      ^~
a.cc:124:49: error: 'class Dice' has no member named 'n2'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                                                 ^~
a.cc:124:58: error: 'class Dice' has no member named 'n2'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                                                          ^~
a.cc:124:69: error: 'class Dice' has no member named 'n3'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                                                                     ^~
a.cc:124:78: error: 'class Dice' has no member named 'n3'
  124 |                     if(d[i].n1==d[j].n1 && d[i].n2==d[j].n2 && d[i].n3==d[j].n3 &&
      |                                                                              ^~
a.cc:125:29: error: 'class Dice' has no member named 'n4'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                             ^~
a.cc:125:38: error: 'class Dice' has no member named 'n4'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                                      ^~
a.cc:125:49: error: 'class Dice' has no member named 'n5'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                                                 ^~
a.cc:125:58: error: 'class Dice' has no member named 'n5'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                                                          ^~
a.cc:125:69: error: 'class Dice' has no member named 'n6'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                                                                     ^~
a.cc:125:78: error: 'class Dice' has no member named 'n6'
  125 |                        d[i].n4==d[j].n4 && d[i].n5==d[j].n5 && d[i].n6==d[j].n6){
      |                                                                              ^~
a.cc:136:14: error: expected '}' at end of input
  136 |     return 0;
      |              ^
a.cc:56:1: note: to match this '{'
   56 | {
      | ^