Question: using C writing a simple recursive passing values to functions Exercise #2 - Finding LCM Exercise Objectives Writing a simple recursive Passing values to functions


Exercise #2 - Finding LCM Exercise Objectives Writing a simple recursive Passing values to functions Problem Description Inside "Lab8" folder, create a project named "Lab8Ex2". Use this project to write and run a C program that performs the following: Prompts the user to input two integer numbers (N, M) Pass those numbers to a function named findL.CM, which finds and returns the least common multiple of N and M In the main function, your program should call findLCM receive and print the returned value [Hint1: LCM (Least Common Multiple), or sometimes called smallest common multiple (SCM), of two numbers is the smallest number which can be divided by both numbers.) [Hinta: LCM (Least Common Multiple), or sometimes called smallest common multiple (SCM), of two numbers is the smallest number which can be divided by both numbers.] 24 multiples of 12-12 36 48 60 72 LCM (12,30) = 60 multiples of 30 - 30 90 Lowest common multiple of 12 and 30 Organize the output to appear as shown in the sample output below -- Finding LCM - Do Enter the first number: 12 Enter the second number: 24 LCM of 12 and 24 is 24
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
