xxx=input()
a=int(xxx.split(' ')[0])
b=int(xxx.split(' ')[1])
print(a//b,a%b)




1  int()取整
2 split() 分割
3  //  地板除              
% 取余数