View the step-by-step solution to: Write a program that prompts a user to enter numbers, determines

Write a program that prompts a user to enter numbers, determines how many positive and negative values have been entered, and computes the sum and average of the numbers entered, not counting zeros. Your program should prompt the user for the number of values that will be entered. It should also contain a while loop to make sure the user enters an integer for the number of values and a for loop to prompt the user for values and calculate the statistics.
Display the output in this order: number of positive values, number of negative values, sum and average.

Recently Asked Questions

Why Join Course Hero?

Course Hero has all the homework and study help you need to succeed! We’ve got course-specific notes, study guides, and practice tests along with expert tutors and customizable flashcards—available anywhere, anytime.


Educational Resources
  • -

    Study Documents

    Find the best study resources around, tagged to your specific courses. Share your own to gain free Course Hero access or to earn money with our Marketplace.

    Browse Documents
  • 890,990,898

    Question & Answers

    Get one-on-one homework help from our expert tutors—available online 24/7. Ask your own questions or browse existing Q&A threads. Satisfaction guaranteed!

    Ask a Question
  • 890,990,898


    Browse existing sets or create your own using our digital flashcard system. A simple yet effective studying tool to help you earn the grade that you want!

    Browse Flashcards