Write program which reads n numbers from keyboard

Assignment Help C/C++ Programming
Reference no: EM1388932

Write down C++ program which reads N numbers (positive, negative, integer and double numbers) from keyboard, computes and shows the following information.

a. Count of all negative numbers. If no negative numbers are entered, 0 for count value must be displayed.
b. Sum of all positive numbers. If no positive numbers are entered, 0 for sum value must be displayed.
c. Average of first two negative numbers. If two negative numbers are not entered, 0 for average value must be displayed.
d. Largest number of all numbers entered from keyboard.
e. Reverse order of first two numbers. Reverse order of two numbers 3.2 6.5 is 6.5 3.2.
f. Area (area = pi*r2) using smallest positive number as radius (r) and pi=3.14.
N must be declared as constant in your program and it must be equal to largest digit of your student id number. Suppose N=2, if largest digit of your student id number is less than 2.
The program must contain only main function. User defined functions and arrays must not be used.

Reference no: EM1388932

Questions Cloud

The approximated value of the company''s before-tax marr : What is the approximated value of the company's before-tax MARR? Determine the GDS depreciation amounts in years on through eight.
Who has priority to the collateral : Metro claims that at the time of its loan it was unaware of HFCs interest. Among these parties, who has priority to the collateral? Discuss your answer.
What is the average power developed by the car engine : A car with a mass of 1.50x10^3 kg starts from rest and accelerates to a speed of 18.0 m/s in 12s. Assume that the force of resistance remains constant at 400-N all through this time. What is the average power developed by the car's engine?
Fundamentals of chebyshev theorem : When using the normal distribution (empirical rule) to obtain the bounds for a 99.73 percent of the values in a population, the interval generall will be _________________ the interval obtained for the same percentage if Chebyshev's theorem is ass..
Write program which reads n numbers from keyboard : Write down C++ program which reads N numbers (positive, negative, integer and double numbers) from keyboard, computes and shows the following information. Largest number of all numbers entered from keyboard.
Recognition sequence of the enzyme : A microbiologist found a new restriction endonuclease. When DNA is digested by this enzyme, fragments that average 1,048,500 bp in length are produced.
For legal advice about my liability with respect : For legal advice about my liability with respect to the conduct of my agents in another state. I am trying to find information about relevant
Illustrate what arguments would you use to convince : Many mainstream retailers are still hesitant to post customer reviews. If you were consulting with one of these companies, illustrate what arguments would you use to convince management to try them?
Define the magnitude of the acceleration of the boy : A hiker's trip consists of three segments. Path A is 8-km long heading 60.0 degrees north of east. Path B is 7.0 km long in a direction due east. Path C is 4sa-km long heading 315 degrees counter clockwise from east. Graphically add hiker's displa..

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

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