Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

#38 and #39 please and thank you 38. (2 pts) Write a while loop (program fragment) to print the numbers on a line from 4

#38 and #39

image text in transcribed

please and thank you

38. (2 pts) Write a while loop (program fragment) to print the numbers on a line from 4 to 11 with one space between them. The output should look exactly like this: 4 5 6 7 8 9 10 11 39. (2 pts) Write an if statement (program fragment) that sets the variable "cat" equal to 17 if the variable "dog" is greater than 11 and the variable "fish" is less than 21. Assume all variables have been previously defined as ints

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

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

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

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

Get Started

Students also viewed these Databases questions