#include using namespace std; typedef long long int ll; typedef pair P; typedef vector VI; typedef vector VVI; #define REP(i,n) for(ll i=0;i<(n);i++) #define ALL(v) v.begin(),v.end() constexpr ll MOD=1000000007; constexpr ll INF=1e18; int main(){ int w, h, x; cin >> w >> h >> x; if(x>36||w%3!=2||h%3!=2){ cout << -1 << endl; } else{ int a[3][3]={0}; REP(i,2)REP(j,2){ a[i][j]=min(9,x); x-=min(9,x); } REP(i,h){ REP(j,w){ cout << a[i%3][j%3]; } cout << endl; } } return 0; }