Feedback for POPCORN problem

Problem Link: POPCORN Problem - CodeChef

my code is correct only but still gets a error can you please check whats the problem
for t in range(int(input())):
a1,a2 = map(int,input().split())
b1, b2 = map(int,input().split())
c1, c2 = map(int,input().split())
print(max((a1+a2),(b1+b2),(c1+c2)))

waiting for your replies

Try running my code once:

#include <iostream>
using namespace std;

int main() {
    
	int t;
	cin>>t;
	while (t--){
	    int a,b,c,d,e,f;
	    cin>>a>>b>>c>>d>>e>>f;
	    
	    if((a+b)>(c+d)){
	        
	        if((a+b)>(e+f)){
	            cout<<a+b<<endl;
	        }
	        
	        else{
	            cout<<e+f<<endl;
	        }
	        
	        
	    }
	    
	    
	    
	    else if((a+b)<(c+d)){
	        
	        if((c+d)>(e+f)){
	            cout<<c+d<<endl;
	        }
	        
	        else{
	            cout<<e+f<<endl;
	        }
	        
	        
	    }
	    
	    else{
	        cout<<a+b<<endl;
	    }
	   
	}

	return 0;
}

Thanks i will