#include #include #include #include #include using namespace std; int main() { /* Enter your code here. Read input from STDIN. Print output to STDOUT */ int t; cin>>t; while(t--) { int n,i; cin>>n; long long x[n]; for(i=0;i>x[n]; int sum = 0; for(i=0;i0) { k = t%10; sum = sum + k; t = t/10; } } cout<