Odd entries and the even entries

Assignment Help Basic Computer Science
Reference no: EM131483824

Write a C++ program that prompts the user for numbers from cin. Stop reading numbers when the input value is zero. Display the total of the odd entries and the even entries.

For example:

Entry 1: 34

Entry 2: 87

Entry 3: 10

Entry 4: 72

Entry 5: 26

Entry 6: 64

Entry 7: 0

Odd entries add up to: 70

Even entries add up to: 223

NOTE THAT "odd " and "even" here refer to the position in the list, not whether the data value is odd or even!

Another example:

Entry 1: 22

Entry 2: 33

Entry 3: 44

Entry 4: 55

Entry 5: 66

Entry 6: 77

Entry 7: 88

Entry 8: 99

Entry 9: 11

Entry 10: 0

Odd entries add up to: 231

Even entries add up to: 264

Reference no: EM131483824

Questions Cloud

Different types of execute support systems : Research 3 different types of Execute Support Systems using the internet. Review each and then answer the following questions.
Interpret the primal in economic terms : Given the input supply functions of a pure monopsonist, where G is a symmetric positive semidefinite matrix, and given the following primal problem.
Common encryption algorithms and methods : Select any three (3) encryption algorithms and develop a well-researched, well-developed paper that would provide a non-technical reader.
Develop a memorandum addressed to the cfo : You will develop a memorandum addressed to the CFO that explains how you want to change your IT Department into a CIO organization and why.
Odd entries and the even entries : Stop reading numbers when the input value is zero. Display the total of the odd entries and the even entries.
Create forms and reports using the skills learned in the lab : Your task is to create forms and reports using the skills learned in the lab. For now, we will not worry about authentication and security.
Ticketing system for a very simple airline : Your employer has determined a market for a simple airline ticketing system for a very simple airline (Tree Top Airways - TTA).
Derive the dual problem and interpret each component : A pure monopolist on two distinct and separated final commodity markets faces prices p1 = c1 - D1x1 and p2 = c2 - D2x2, respectively, where Di are asymmetric.
Whatever is done in excel you have to do it in python : Whatever is done in excel you have to do it in python. Like you have to categorize the tweets related to app and other. It should be done by using pandas

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd