AtCoder Mart sells 1000000 of each of the six items below:    * Riceballs, priced at 100 yen (the currency of Japan) each   * Sandwiches, priced at 101 yen each   * Cookies, priced at 102 yen each   * Cakes, priced at 103 yen each   * Candies, priced at 104 yen each   * Computers, priced at 105 yen each  Takahashi wants to buy some of them that cost exactly X yen in total. Determine whether this is possible.   (Ignore consumption tax.)
# your code goes here
x=int(input())
ans=list(str(x))
a=int(ans[len(ans)-2]+ans[len(ans)-1])
if 5*(x//100)>=a:
	print('YES')
else:
	print('NO')
# your code goes here
x=int(input())
ans=list(str(x))
a=int(ans[len(ans)-2]+ans[len(ans)-1])
if 5*(x//100)>=a:
	print(1)
else:
	print(0)