Write the suitable snip code using for statement to display the number of apples sold each even day in first half of June as outpi display in Figure 2. Figure 2: OUTPUT CONSOLE Number of apples sold on Day 2 of June: 23 Number of apples sold on Day 4 of June: 24 Number of apples sold on Day 6 of June: 27 Number of apples sold on Day 8 of June: 21 Number of apples sold on Day 10 of June: 22 Number of apples sold on Day 12 of June: 29 Number of apples sold on Day 14 of June: 22

Np Ms Office 365/Excel 2016 I Ntermed
1st Edition
ISBN:9781337508841
Author:Carey
Publisher:Carey
Chapter8: Working With Advanced Functions
Section: Chapter Questions
Problem 1.10CP
icon
Related questions
Question
100%
C++ programming
Write the suitable snip code using for statement to display the number of apples sold each even day in first half of June as output
display in Figure 2.
Figure 2: OUTPUT CONSOLE
Number of apples sold on Day 2 of June: 23
Number of apples sold on Day 4 of June: 24
Number of apples sold on Day 6 of June: 27
Number of apples sold on Day 8 of June: 21
Number of apples sold on Day 10 of June: 22
Number of apples sold on Day 12 of June: 29
Number of apples sold on Day 14 of June: 22
Note: Assume the bold word in output console is initialize value of array already written at the beginning of
the code as shown below.
int apple [15] = {25, 23, 26, 24, 22, 27, 30, 21, 20, 22, 28, 29, 23, 22, 27}
Transcribed Image Text:Write the suitable snip code using for statement to display the number of apples sold each even day in first half of June as output display in Figure 2. Figure 2: OUTPUT CONSOLE Number of apples sold on Day 2 of June: 23 Number of apples sold on Day 4 of June: 24 Number of apples sold on Day 6 of June: 27 Number of apples sold on Day 8 of June: 21 Number of apples sold on Day 10 of June: 22 Number of apples sold on Day 12 of June: 29 Number of apples sold on Day 14 of June: 22 Note: Assume the bold word in output console is initialize value of array already written at the beginning of the code as shown below. int apple [15] = {25, 23, 26, 24, 22, 27, 30, 21, 20, 22, 28, 29, 23, 22, 27}
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Introduction to computer system
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
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage
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