For the organization of the center for distance education, all schools in the city had to be connected in pairs by conductive communication channels, and in each school, all the wires coming to it are connected to each other. Each channel is a conductor with resistance , and this value is the same for all the established lines (there is no need to discuss the advisability—the experts decided so). When connecting each school, starting from the third one, technicians measured the resistance between every pair of schools connected to the network at this stage, using a very accurate digital ohmmeter. When all schools were connected, they counted how many times the measurement results turned out to be an integer. Let your program compute this as well.
The program reads the first integer —the resistance between each pair of schools (1 \leq R \leq 10000), followed by a positive integer (3 \leq N \leq 10000)—the number of schools. The numbers are given in one line, separated by a space.
The program prints one integer—the number of measurements that were integers.
Example 1