Question

13-   Write the program that gets three number Start, End , STEP Then shows: Start, Start...

13-   Write the program that gets three number Start, End , STEP
Then shows: Start, Start + Steps, Start + step+Step ……. Less or Equal End
Example if Start: 7 , 35, 67 , 13, 19,25,31

use python pls

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Code:

Start = int(input("Enter value for Start: "))
End = int(input("Enter value for End: "))
STEP = int(input("Enter value for Step: "))

print("The required array: ")

for i in range(Start,End,STEP):
    print(i,end=" ")

Output:

Enter value for Start: 7 Enter value for End: 35 Enter value for Step: 6 The required array: 7 13 19 25 31 - GDB Program fini

Add a comment
Know the answer?
Add Answer to:
13-   Write the program that gets three number Start, End , STEP Then shows: Start, Start...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • In Python, Using this formula: Using this setup: Gets this output: 1) Write a function called...

    In Python, Using this formula: Using this setup: Gets this output: 1) Write a function called myCos(x) that accepts an input number x measured in degrees la. Therefore, your function needs to first convert a degree to a radian. For example, if x is 67 degrees, x can be converted to a radian as follows: x = 67 # x is 67 degrees. x-x/ 180 * math.pi # x is now measured in radian. You can stop your loop after...

  • Python Program Python: Number Guessing Game Write a Python function called "Guess.py" to create a number...

    Python Program Python: Number Guessing Game Write a Python function called "Guess.py" to create a number guessing game: 1. Function has one input for the number to Guess and one output of the number of attempts needed to guess the value (assume input number will always be between 1 and 1000). 2. If no number was given when the function was called, use random.randint(a,b) to generate a random number between a=1 and b=1000. You will also need to add an...

  • Write a program that first gets a list of integers from the input and adds them...

    Write a program that first gets a list of integers from the input and adds them to an array. The input begins with an integer indicating the number of integers that follow (Your program should work for any size of the array). Then, get the last value from the input, and output all integers less than or equal to that value by iterating through the array. Ex: If the input is: Enter the number of integers: 5 Enter integer 1:...

  • C++ pls use iostream Write a program that prompts the user to enter 5 exam marks...

    C++ pls use iostream Write a program that prompts the user to enter 5 exam marks (design your program such that It would be easy to change if we wanted it to work for more than 5 earns). The program python displays the average mark, the highest mark, and number of marks entered less than the average mark

  • 4.12 LAB: Smallest number Write a program whose inputs are three integers, and whose output is...

    4.12 LAB: Smallest number Write a program whose inputs are three integers, and whose output is the smallest of the three values. Ex: If the input is: 7 15 3 the output is: 3 I have to write this in python, having a hard time deciding how to approach this. Thank you!

  • Overview Module 3 Assignment 1 features the design of a pseudocode and a Python program that...

    Overview Module 3 Assignment 1 features the design of a pseudocode and a Python program that uses iteration to guess a number from 1 to 10. Each lab asks you to write pseudocode that plans the program’s logic before you write the program in Python and to turn in three things: 1) the pseudocode, 2) a screenshot of the output, and 3) the Python program. Instructions Write pseudocode for a Python program that uses iteration to guess a number from...

  • please write in python Write a program that asks for beginning and ending number. The program...

    please write in python Write a program that asks for beginning and ending number. The program generates a set of 20 random numbers between the numbers and displays a count of each number generated. Sample output Enter starting and ending number separated by comma: 5, 25 5 occurs 2 times 7 occurs 1 time 8 occurs 1 time 10 occurs 2 times 12 occurs 1 time 13 occurs 2 time 15 occurs 5 times 16 occurs 1 time 20 occurs...

  • This is a python work, thank for helping! 7. (6 points) Write a function, countOfAndSmalest Number...

    This is a python work, thank for helping! 7. (6 points) Write a function, countOfAndSmalest Number Between(low, high, ignore, listOfNumbers), that takes as input three numbers and a list of numbers, and returns a list containing two items: 1) how many items in listOfNumbers are greater than low, less than high, and not equal to ignore 2) the smallest number in listOfNumbers that is greater than low, less than high, and not equal to ignore (or None if there is...

  • Write the following in Ruby code NOT scheme 5 (build-list start end) Return a list of...

    Write the following in Ruby code NOT scheme 5 (build-list start end) Return a list of integers starting with start (inclusive) and ending with end (exclusive). Note, if end is less than or equal to start, this should return an empty list See functions: <= For example: schemeO (guile -user)> (build-list 0 5) $19-(0 1 2 3 4) scheme0 (guile-user)> (build-list 5 0) $20 = () schemeO (guile-user> (build-list 10 15) $21 = (10 11 12 13 14)

  • Write a Python program that does the following: Obtains the following input from a user: Mileage...

    Write a Python program that does the following: Obtains the following input from a user: Mileage at beginning of measurement period Mileage at end of measurement period Gallons of fuel consumed Calculates and displays: Miles driven Miles per gallon Kilometers driven Liters of fuel consumed Kilometers per liter Incorporate some Selection structure logic into it: If a vehicle gets less than 15 miles per gallon, display the message:       "Your vehicle has criminally low fuel efficiency." If it gets 15...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT