Good arrays
시간 제한: 2000ms메모리 제한: 1024MB출처: MOOI 2021-22 finalBOJ 30668
문제
Recently Vasya learned about integer division. Inspired by this sacred knowledge, he decided to learn more about arrays of positive integers which satisfy some divisibility conditions. More precisely, Vasya calls an array good iff for every from to , is divisible by . Please help him count the number of good arrays of length consisting of integer numbers not greater than .
입력
The only input line contains two integers and () --- the length of the array and the maximum allowed value.
출력
Output a single integer --- the total number of good arrays of length consisting of positive integers not greater than . As this number might be quite large, please output its remainder modulo .
예제
예제 1
입력
3 3
출력
7
예제 2
입력
2 6
출력
14
코드를 제출하려면 로그인하세요.