3 ☐ ☐ ☐ ☐ Write a for loop that iterates 6 times. Each iteration: Put userNum to output. Then, put "-" to output. Then, assign userNum with userNum multiplied by 4. Ex: If input is 2, then output is: 2-8-32-128-512-2048- 1 integer userNum 2 integer i 3 4 // Program will be tested with inputs: 2 and 3 5 userNum = Get next input 6 7 Variables Not shown when editing 8 Your solution goes here 9 Code Flowchart 4

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter5: Looping
Section: Chapter Questions
Problem 13RQ
icon
Related questions
Question
3
☐ ☐ ☐ ☐
Write a for loop that iterates 6 times. Each iteration: Put userNum to output. Then, put "-" to output. Then,
assign userNum with userNum multiplied by 4.
Ex: If input is 2, then output is:
2-8-32-128-512-2048-
1 integer userNum
2 integer i
3
4 // Program will be tested with inputs: 2 and 3
5 userNum = Get next input
6
7
Variables
Not shown when editing
8 Your solution goes here
9
Code Flowchart
4
Transcribed Image Text:3 ☐ ☐ ☐ ☐ Write a for loop that iterates 6 times. Each iteration: Put userNum to output. Then, put "-" to output. Then, assign userNum with userNum multiplied by 4. Ex: If input is 2, then output is: 2-8-32-128-512-2048- 1 integer userNum 2 integer i 3 4 // Program will be tested with inputs: 2 and 3 5 userNum = Get next input 6 7 Variables Not shown when editing 8 Your solution goes here 9 Code Flowchart 4
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
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