1506: 【入门】姐妹数对

Memory Limit:32 MB Time Limit:1.000 S
Judge Style:Text Compare Creator:
Submit:2 Solved:2

Description

给定两个不同的正整数x,y,若x+y能被3除尽或能被7除尽,则称x,y为姐妹数对。例如:
2,4;2,5;为姐妹数对。
3,14;    不是姐妹数对。
那么,对给出的一个整数n(1≤n≤100), 1,2,…,n之间有多少个姐妹数。

Input

一个整数n

Output

一个整数,即1~n之间姐妹数对的个数。

Sample Input Copy

6

Sample Output Copy

8