Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

(1) Prompt the user to input an integer, a double, a character, and a string, storing each into separate variables. Then, output those four values

(1) Prompt the user to input an integer, a double, a character, and a string, storing each into separate variables. Then, output those four values on a single line separated by a space. Note: This zyLab outputs a newline after each user-input prompt. For convenience in the examples below, the user's input value is shown on the next line, but such values don't actually appear as output when the program runs.

Enter integer: 99 Enter double: 3.77 Enter character: z Enter string: Howdy 99 3.770000 z Howdy

(2) Extend to also output in reverse. (1 pt)

Enter integer: 99 Enter double: 3.77 Enter character: z Enter string: Howdy 99 3.770000 z Howdy Howdy z 3.770000 99

(3) Extend to cast the double to an integer, and output that integer.?

Enter integer: 99 Enter double: 3.77 Enter character: z Enter string: Howdy 99 3.770000 z Howdy Howdy z 3.770000 99 3.770000 cast to an integer is 3

2.36 LAB: Warm up: Variables, input, and casting (1) Prom the ser to put an interades senasts and assingsring an inte separat

2.36 LAB: Warm up: Variables, input, and casting (1) Prompt the user to input an integer a double, a character and a string, storing each into separate variables. Then, output those four values on a single line separated by a space. (2 pts) Note: This zyLab outputs a newline after each user-input prompt. For convenience in the next line, but such values don't actually appear as output when the program runs. Enter integam: Enter double: 3.77 Enter character: Enter ating: Howdy 99 3.770000 = Bondy (2) Extend to also output in reverse (1 pt) Enter intagar Enter double: 3.77 Enter character: Enter atsing: Howdy 99 3.770000 = Bondy Howdy 3.770000 99 (3) Extend to cast the double to an integer, and output that integer (2 pts) Enter intagem: 99 Enter double: 3.77 Enter character: Enter string: Howdy 99 3.770000 = Bondy Howdy 3.770000 99 3.770000 cast to an integer i 3 les balonc ar's input value is shown on

Step by Step Solution

3.36 Rating (159 Votes )

There are 3 Steps involved in it

Step: 1

Code Screenshots Sample Output Code to Copy Include the required header files include Define the ... blur-text-image
Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Matlab An Introduction with Applications

Authors: Amos Gilat

5th edition

1118629868, 978-1118801802, 1118801806, 978-1118629864

More Books

Students explore these related Mechanical Engineering questions

Question

23. What causes astigmatismpg78

Answered: 3 weeks ago