1731: 【CSP循环】能被5整除且至少有一位数字是5的所有整数的个数▅

Memory Limit:128 MB Time Limit:1.000 S
Judge Style:Text Compare Creator:
Submit:10 Solved:9

Description

找出 lns="http://www.w3.org/1998/Math/MathML">1N 中能被 lns="http://www.w3.org/1998/Math/MathML">5 整除且至少有一位数字是 lns="http://www.w3.org/1998/Math/MathML">5 的所有整数的个数。( lns="http://www.w3.org/1998/Math/MathML">N<32767)。

Input

输入只有一行,只有 lns="http://www.w3.org/1998/Math/MathML">1 个整数 lns="http://www.w3.org/1998/Math/MathML">N 

Output

输出只有一行(这意味着末尾有一个回车符号),包括 lns="http://www.w3.org/1998/Math/MathML">1 个整数。

Sample Input Copy

9999

Sample Output Copy

1271