How many natural numbers can be taken from 1, 2, 3, 1998 and 1999 so that the difference between any two numbers is not equal to 5

How many natural numbers can be taken from 1, 2, 3, 1998 and 1999 so that the difference between any two numbers is not equal to 5


Answer: 1000 numbers divide the 1999 numbers 1,2,3.19981999 into five equal difference arrays: one, 1,6,11,16.19911996 --- a total of 400 numbers; two, 2,7,12,17.19921997 --- a total of 400 numbers; three, 3,8,13,18.19931998 --- a total of 400 numbers; four, 4,9,14,19.19941999



In the 100 continuous natural numbers from 0 to 99, the multiples of 5 and 3 are removed, and the remaining ones are sorted from large to small


Among the 100 numbers, the multiple of 3 is 99 divided by 3 to get 33, the multiple of 5 is 99 divided by 5 to get 19 more than 4, that is, there are 19, the repeated number is 99 divided by (3 * 5) to get 6 more than 9, that is, there are 6 in common