numpy.lcm(arr1, arr2, out = None, where = True, casting = ‘same_kind’, order = ‘K’, dtype = None) : This mathematical function helps user to calculate lcm value of |arr1| and |arr2| elements.
arr1 / arr2 : [array_like]Input array.
Return : LCM of two or more numbers.
arr1 : [120, 24, 42, 10] arr2 : [2250, 12, 20, 50] lcm of arr1 and arr2 : [9000, 24, 420, 50] lcm of arr1 and 10 : [120, 120, 210, 10]
- Python | Merge Python key values to list
- Important differences between Python 2.x and Python 3.x with examples
- Python | Index of Non-Zero elements in Python list
- Reading Python File-Like Objects from C | Python
- Python | Convert list to Python array
- Python | Sort Python Dictionaries by Key or Value
- Python | Set 4 (Dictionary, Keywords in Python)
- Python | Add Logging to Python Libraries
- Python | Add Logging to a Python Script
- Python | Visualizing O(n) using Python
- Any & All in Python
- try-except vs If in Python
- SQL using Python | Set 1
- zip() in Python
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.