Question: Please show how to write this code thanks. Write a program that: Asks a user to enter a number between 4-6. This input should be
Write a program that: Asks a user to enter a number between 4-6. This input should be stored in a variable called num. If they enter a number out of range (not 4, 5 or 6), the program should say "Number out of range!" and exit. Ask a user to enter a word with at least num (what the user entered before) letters and at most 10 letters. If they enter a word longer than this, the program should say "Too many letters!" and end. If they enter a word shorter than num letters, the program should say "Too few letters!" and end. Ask the user to enter another number between 1-3 and store it in a variable called num2. You should print out that many letters of the word from the beginning. Please enter a number between 4-6: 5 Enter a word with at least 5 letters and less than 10 letters: seashell Please enter another number: 3 sea
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
