#include<bits/stdc++.h> using namespace std; int main(){ cout<<1051<<endl; cout<<81<<endl; cout<<5521<<endl; return 0; }