Answer is 2519.
It can be obtained by simple application of factorials, consider the smallest number divisible by all 10,9,8,7,6,5,4,3,2,1 and calculate it, which can be given by, 2x2x2x3x3x5x7=2520=M+1(because we must get remainder of 1, when it is divided by 2).
Hence, M=2519, which is the solution.
Now to crosscheck it, 2519-1=2518->divisible by 2.
2519-2=2517->divisible by 3.
2519-3=2516->divisible by 4
2519-4=2515, divisible by 5
2519-5=2514, divisible by 6
2519-6=2513, divisible by 7
2519-7=2512, divisible by 8,
2519-8=2511, divisible by 9,
2519-9=2510, divisible by 10.