Create IPO charts for each of the following: Write a program to input a number N. If the number is greater than 50, subtract 10 from the number; otherwise multiply the number by 2 and add 5. Print the number and the result.
Create IPO charts for each of the following: Write a program to input a number N. If the number is greater than 50, subtract 10 from the number; otherwise multiply the number by 2 and add 5. Print the number and the result.
Chapter6: Looping
Section: Chapter Questions
Problem 14PE
Related questions
Question
Create IPO charts for each of the following:
- Write a
program to input a number N. If the number is greater than 50, subtract 10 from the number; otherwise multiply the number by 2 and add 5. Print the number and the result. - Three football teams are awarded points based on matches they played. Read the team, the team total and whether it won, drew or lost the match and print the team total. Award the points to the teams total points as follows: 2-win, 1-drawn, 0-lost.
- Write a program to print the average age and height of students in a class of 35. Read the age and height of each student.
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 2 steps with 3 images
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr