Cody is late for class. But turns out, John is late too. The class decided that to save time, they shouldn't have both of them count 0-99.   After discussions, they decided that Cody should count all even numbers from 0-99 and John count the odd numbers. Use a loop and print all even numbers from 0-99. Output A series of all even integers within 0 to 99. 0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96 98

C++ for Engineers and Scientists
4th Edition
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Bronson, Gary J.
Chapter5: Repetition Statements
Section5.5: A Closer Look: Loop Programming Techniques
Problem 14E
icon
Related questions
Question

Please help me find the C CODE for this problem. Thank you!

2. Counting Even

by CodeChum Admin

Cody is late for class. But turns out, John is late too. The class decided that to save time, they shouldn't have both of them count 0-99.

 

After discussions, they decided that Cody should count all even numbers from 0-99 and John count the odd numbers. Use a loop and print all even numbers from 0-99.

Output

A series of all even integers within 0 to 99.

0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96 98
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Random Class and its operations
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++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
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