Finds the smallest number that can be divided by a sequential set of numbers from 1 till a given range
Example: 1,2,3,4,5 = 60
60 is the smallest number that can be divided by each of the numbers from 1 to 5 without any remainder.
This program is intended to extend another application. For instance as (micro)service to your existing product
#Instructions:
Perform a GET-request to path: localhost:8080/LeastCommonMultipleTill, proceeded with a query parameter: till
Tip: Use an http client like Postman to test the requests.
Example:
localhost:8080/LeastCommonMultiple?till=13
The API will return a string containing:
360360 is the smallest number that can be divided by each of the numbers from 1 to 13 without any remainder.
Notes & Limits:
- Inserting value other than number will return statuscode of 400 - BAD Request
- Note that its not possible to request a maximum range greater then 42
- Results of this application are tested based on the standards of Calculator.net
Prerequisites: Maven is installed on the machine & the project is unzipped.
-
Navigate to the projects root directory /West - Assignment. (See that the pom.xml is located here)
-
Run command:
mvn spring-boot:run
- To skip tests run:
mvn -DskipTests spring-boot:run
- To quit application run: ctrl + c,
Terminate Batch Job(Y/N)?:
N (Kill in task manager if necessary)
- To skip tests run:
-
Follow usage instructions
Prerequisites: Maven is installed on the machine & the project is unzipped.
1. Install Project:
Direct install of Project github.com/1eam/Least_Common_Multiple_Calculator/archive/refs/heads/master.zip
2. Install maven:
https://dlcdn.apache.org/maven/maven-3/3.8.3/binaries/apache-maven-3.8.3-bin.zip [Download of 03-11-21]
3. Add Maven to classpath:
Navigate to Environment Variables
In the bottom tab (System Variables) double-click on 'Path' and add the /apache-maven-3.8.3/bin
directory
3.2 Test successful installation of maven:
run: mvn -v
response should look like:
Install reference: https://maven.apache.org/install.html#
- Ability to calculate LCM of range x till x. Example: 3 - 45, 13 - 17, 19 - 23
- Ability to calculate LCM of x numbers. Where x are multiple random numbers. Example 23, 4, 15 and 8 = 2760
none Free Software✨