Submit | All submissions | Best solutions | Back to list |
RETO1AGO - RETO MCM |
The least common multiple of several numbers is the smallest number that is a multiple of all of them at once.
For example, the LCM of 3 and 7 is 21, the 4 and 12 is 12, and 9 and 12 is 36.
The user will enter three whole numbers (positive, of no more than 5 digits), one per line. Your program should display the least common multiple of these three numbers.
Caution: As usual in the programming challenges, follow exactly the inputs and outputs (see example.) This is NOT an interactive program, and must not prompt the user with phrases like "Enter a number" or "Give me a number". You should only take three numeric integer data from standard input, analyze and display a result will also be an integer. Similarly, there should be no pause before or after the execution of the program.
Input
The input data must be positive integers that are going to calculate the MCM numbers.
Output
The output should be a positive integer response to the operation of MCM.
Example
Input: 3 7 2 Output: 42
Added by: | MARATON AFDM |
Date: | 2015-08-25 |
Time limit: | 1s |
Source limit: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | MAWK BC C NCSHARP CSHARP C++ 4.3.2 CPP14 COFFEE DART FORTH JAVA JS-RHINO JULIA KTLN OCT PHP PROLOG PYPY3 R RACKET SQLITE SWIFT UNLAMBDA |
Resource: | http://www.nachocabanes.com/retos/reto.php?n=023 |
hide comments
2015-08-25 18:43:26 Francky
Moved. |
|
2015-08-25 17:48:03 Jaswanth
Simple one :--> Tutorial |
|
2015-08-25 15:12:23 Rishav Goyal
does anyone think that "life,universe and everything" is still better problem than this :D XD |
|
2015-08-25 13:52:45 :?ToRpiDo
Tutorial stuff ! |
|
2015-08-25 13:48:35 mehmetin
Problem too trivial. Not even tutorial. |
|
2015-08-25 07:38:01 kp
Resource contains solution. Please fix it!! |
|
2015-08-25 07:07:49 ram
Make the language of the question clear (Input output format is not clear). And also correct the output of the example. |