Question: In Python Problem 1 Open PyCharm ( or IDLE or your favorite IDE ) and create a New File named lab 2 p 1 .
In Python
Problem
Open PyCharm or IDLE or your favorite IDE and create a New File named labp py
Write a program that prints the odd numbers between and using a for loop.
Now modify the program to put all the output on one line, with the values separated by commas.
Modify the program to print the even numbers between values. Put all the output on one line, with the values
separated by commas.
Modify the program to ask the user for the two values.
Save this final version of the program for submission.
Program
Close the file from Program and create a New File named labppy
Write a program that prints the odd numbers between and using a while loop.
Now modify the program to put all the output on one line, with the values separated by commas.
Modify the program to print the even numbers between values. Put all the output on one line, with the values
separated by commas.
Modify the program to ask the user for the two values.
Save this final version of the program for submission.
Program
Close the file from Program and create a New File named labp py
The greatest common divisor GCD is the largest value that divides two integers evenly, no remainder. Write a program to
accept two integers of input from the user and report the GCD of the two integers. The most straight forward way to find this
is to repeatedly divide both integers by possible divisors, beginning with the smaller of the two integers.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
