B1. Write a selection statement (NOT a complete program) to determine the wave description based on the wave height and display the wave description according to the following table. Assume waveHeight is a double variable, and no need to declare or initialize the waveHeight variable. Wave Height (in mater) Wave Description Less than 0.5 Smooth Less than 1.25 and greater than or equal to 0.5 Slight Less than 2.5 and greater than or equal to 1.25 Moderate Less than 6 and greater than or equal to 2.5 Rough Greater than or equal to 6 High

C++ for Engineers and Scientists
4th Edition
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Bronson, Gary J.
Chapter1: Fundamentals Of C++ Programming
Section: Chapter Questions
Problem 5PP
icon
Related questions
Question
B1. Write a selection statement (NOT a complete program) to determine the wave description based on the
wave height and display the wave description according to the following table. Assume waveHeight is a double
variable, and no need to declare or initialize the waveHeight variable.
Wave Height (in mater)
Wave Description
Less than 0.5
Smooth
Less than 1.25 and greater than or equal to 0.5
Slight
Less than 2.5 and greater than or equal to 1.25
Moderate
Less than 6 and greater than or equal to 2.5
Rough
Greater than or equal to 6
High
Transcribed Image Text:B1. Write a selection statement (NOT a complete program) to determine the wave description based on the wave height and display the wave description according to the following table. Assume waveHeight is a double variable, and no need to declare or initialize the waveHeight variable. Wave Height (in mater) Wave Description Less than 0.5 Smooth Less than 1.25 and greater than or equal to 0.5 Slight Less than 2.5 and greater than or equal to 1.25 Moderate Less than 6 and greater than or equal to 2.5 Rough Greater than or equal to 6 High
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Graphical User Interface
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.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage