If b is positive, then reduce each of a and b by subtracting 1, repeatedly until b is zero. If b is negative, repeatedly add 1 to both until b is zero. The final value of a is the result you ask for. If a and b are two integers, their sum is a+b, not a-b.
Subtraction
A-b
You can only find the LCM of two non zero integer numbers. This therefore means you cannot find the LCM of 0.5 and 1.75.
231 / 3 = 77So 76 + 77 +78 = 23177
Just enter the numbers in a calculator. If you want to do it by long division, you may find it helpful to multiply both numbers by 10 so that the divisor is an integer. That is, 25.85/0.5 = 258.5/5 = 51.7
Subtraction
A-b
Subtraction a-b
addition a + b
71 is, itself an integer but to find a difference you require 3 numbers.71 is, itself an integer but to find a difference you require 3 numbers.71 is, itself an integer but to find a difference you require 3 numbers.71 is, itself an integer but to find a difference you require 3 numbers.
The procedure is known as "addition", with the possible additional requirement of "carrying" depending on the specific integers.
You need at least two numbers to find an LCM.
You need at least two numbers to find an LCM and they both have to be integers, but the LCM of 1 and any positive integer is that integer.
The numbers are 9 and 10.
The following is for F95 and later (due to the use of intrinsic SUM ): My assumptions: -Your numbers are integers -Your numbers are stored in an array -The numbers you are describing are 0-100 program findSum !I assumed integer, replace this with your data type integer, dimension(100) :: numbers integer :: sumOfNumbers !We populate an array with our numbers !Replace this with your numbers do i=1,(size(numbers)+1) numbers = i end do !We find the sum of those numbers sumOfNumbers = sum(numbers) !We write out the sum to prompt write(*,*) 'Sum is: ', sumOfNumbers end program findSum
The numbers are 14, 16 and 18.
To find an integer you ask your teacher.