Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a for loop that prints userNum . . . - 1 0 . Ex: If the input is: - 3 the output is: -

Write a for loop that prints userNum ...-10.
Ex: If the input is:
-3
the output is:
-3-2-10 #include
using namespace std;
int main(){
int userNum;
int i;
cin >> userNum;
for(/* Your code goes here */){
cout << i <<"";
}
return 0;
}

Step by Step Solution

There are 3 Steps involved in it

Step: 1

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

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

Recommended Textbook for

Beginning C# 2005 Databases

Authors: Karli Watson

1st Edition

0470044063, 978-0470044063

More Books

Students also viewed these Databases questions

Question

Describe Balor method and give the chemical reaction.

Answered: 1 week ago

Question

How to prepare washing soda from common salt?

Answered: 1 week ago

Question

Explain strong and weak atoms with examples.

Answered: 1 week ago

Question

Explain the alkaline nature of aqueous solution of making soda.

Answered: 1 week ago