Number Game
Submissions: 2174   Accuracy:

31.78%

  Difficulty: Easy   Marks: 2

Given a number n the task is to print the minimum number which is divisible by all numbers from 1 to n.

Input:
In first line input a number T denoting the number of Test cases and in the next line input a number N.

Output:
Output in a single line denoting the number which is divisible by all numbers from 1 to N.

Constraints:
1 <= T <= 100

1 <= N <= 30

Example:
Input:
2
3
5
Output:
6
60

Explanation:
Testcase 1: When n=3 then the minimum number that nis divisible all the number till 3 is 6.

** For More Input/Output Examples Use 'Expected Output' option **

Author: Ayush Saluja


If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.



Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.


to report an issue on this page.