#include<bits/stdc++.h> using namespace std; int main(){ int n,m,k,x,y,xy[1000][1000],nx,ny; cin>>n>>m>>k; x=k%m; y=k/m; cout<<nx<<' '<<ny; }