#include<bits/stdc++.h> using namespace std; int main() { int a,b,s,r; cin >> a>>b ; s=a/b; r=a-s*b; cout<< s<<" "<<r; return 0; }