Help me in solving COMMUTE problem

My issue

i can not understand the problem very well

My code

#define fastio() ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
#include <bits/stdc++.h>
using namespace std;
using ull= unsigned long long;
using ll= long long int;
using lld= long double;
# define YES cout << "YES" << endl;
#define MOD 1000000007
# define NO cout << "NO" << endl;

#include <iostream>
using namespace std;


void bhaskar() {
 
  
  
  
}
int main() {
	int t;
	cin>>t;
	while(t--){
	    bhaskar();
	}
	return 0;
}

Problem Link: COMMUTE Problem - CodeChef