Skip to content
CampusEduX

Least Common Multiple

Easyjavapythonccppjavascript

Given two positive integers, find their least common multiple (LCM) — the smallest positive integer divisible by both.

Input Format

A single line containing two integers A and B.

Output Format

Print the LCM of A and B.

Related Problems

  • Check Prime Number
    Easy · java, python, c, cpp, javascript
    Solve Problem
  • Greatest Common Divisor
    Easy · java, python, c, cpp, javascript
    Solve Problem
  • Count Digits and Digit Sum
    Easy · java, python, c, cpp, javascript
    Solve Problem

Input (stdin)

Output

Run your code to see output here...