Trouble with Python Homework using While Loops

Issue

This Content is from Stack Overflow. Question asked by Zach

I’m currently working on some Python homework that’s due in tonight. I previously had this code already done though when going to submit it just before it’s now missing and I don’t remember exactly how to do it as I am on pretty basic levels of python coding for a course.

The Question: Write a Python program using a “While” loop that will ask the user to enter a number as long as the user wants to. When the user is finished, the program should then display the following:
• Number of positive numbers entered by the user
• Number of zeroes entered by the user
• Number of negative numbers entered by the user

Current code I have:



Solution

This question is not yet answered, be the first one who answer using the comment. Later the confirmed answer will be published as the solution.

This Question and Answer are collected from stackoverflow and tested by JTuto community, is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?