1843: BritishCoins(easy)

内存限制:128 MB 时间限制:1.000 S
评测方式:文本比较 命题人:
提交:79 解决:41

题目描述

Prior to 1971, Britain used a system of coins that can be traced back to the time of Charlemagne. The three main units of coinage were the penny, the shilling, and the pound. There were 12 pennies in a shilling and 20 shillings in a pound. Given a number pence of pennies, convert this amount into pounds, shillings, and pennies by first converting as many pennies as possible into pounds, and then converting as many of the remaining pennies as possible into shillings.

输入

pence is between 0 and 10000, inclusive.

输出

Each line three numbers,containing the number of pounds, the number of shillings, and the number of pennies, in that order.

样例输入 复制

533
0
6
4091
10000

样例输出 复制

2 4 5 
0 0 0 
0 0 6 
17 0 11 
41 13 4 

来源/分类