#include<bits/stdc++.h>
using namespace std;
using LL=long long;
using ULL=unsigned long long;
#define rep(i,n) for(int i=0;i<(n);i++)

int main(){
  int N; cin>>N;
  while(N--){
    int d; cin>>d;
    if(d==1) cout<<10<<endl;
    else{ cout<<"9"; cout<<string(d-1,'0')<<endl; }
  }
  return 0;
}