DWITE, October 2012, Problem 2
Besides candy, you have also collected data on how many houses gave out candy on each street. Having this in a handy chart would significantly optimize your candy gathering next year!
The input will contain 5 lines, each a pair of non-negative integers, separated by a single space. The first is the number of houses that gave out candy on that street. The second is the number of houses that did not. There will be at least one house on each street.
The output will contain 5 ASCII percent bar graphs — the ratio of candy-giving houses. Each line will be 10 characters long, and percents will be rounded to the lowest th. E.g. and both round down to . Use asterisk
* for candy part, followed by periods
. for the candy-free houses.
0 1 1 9 19 81 99 1 1 0
.......... *......... *......... *********. **********