|
Exercises - Input-Output
Page history
last edited
by Steve Sweeney 10 years, 6 months ago
- Write a program that prompts the user for their name, age, and address, and then outputs this information using one or two nicely formatted sentences.
- Write a program that asks the user to input marks for 4 courses, and the displays the average mark.
- Ask 5 simple math problems. After the user enters their answer, display the problem and the correct answer. The correct answer should be calculated by your program.
- Ask the user their name, age, and the current year. Greet the user and tell them the year they will be 25, 50, and 75.
- Have the user enter two integers between 1 and 9. Do the basic math operations using these numbers and display the answer (add, subtract, multiply, divide, exponent).
- Using the available help or online resources for your programming language, investigate how to do #2 with your answer rounded to one decimal place.
Exercises - Input-Output
|
Tip: To turn text into a link, highlight the text, then click on a page or file from the list above.
|
|
|
Comments (0)
You don't have permission to comment on this page.