atcoder#SUMITB2019C. 100 to 105
100 to 105
Score: points
Problem Statement
AtCoder Mart sells of each of the six items below:
- Riceballs, priced at yen (the currency of Japan) each
- Sandwiches, priced at yen each
- Cookies, priced at yen each
- Cakes, priced at yen each
- Candies, priced at yen each
- Computers, priced at yen each
Takahashi wants to buy some of them that cost exactly yen in total. Determine whether this is possible. (Ignore consumption tax.)
Constraints
- is an integer.
Input
Input is given from Standard Input in the following format:
Output
If it is possible to buy some set of items that cost exactly yen in total, print 1
; otherwise, print 0
.
615
1
For example, we can buy one of each kind of item, which will cost yen in total.
217
0
No set of items costs yen in total.