What is the output for C++ code below: for(int i=1;i<=5;i++) { if((i%2)!=0) { cout<

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter17: Linked Lists
Section: Chapter Questions
Problem 22SA
icon
Related questions
Question
I need the answer as soon as possible
Question 13
Not yet answered
Marked out of 1.00
P Flag question
What is the output for C++ code below:
for(int i=1;i<=5;i++)
{
if((i%2)!=0)
{
cout<<i<<" ";
}
а.
1 2 3
b. 135
C.
1 25
d. 0 1 2
Transcribed Image Text:Question 13 Not yet answered Marked out of 1.00 P Flag question What is the output for C++ code below: for(int i=1;i<=5;i++) { if((i%2)!=0) { cout<<i<<" "; } а. 1 2 3 b. 135 C. 1 25 d. 0 1 2
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Encryption and Decryption
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++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr