{"id":5147,"date":"2021-12-30T23:15:00","date_gmt":"2021-12-30T17:45:00","guid":{"rendered":"https:\/\/www.codingbroz.com\/?p=5147"},"modified":"2021-12-30T15:31:30","modified_gmt":"2021-12-30T10:01:30","slug":"python-program-to-check-if-a-number-is-positive-negative-or-zero","status":"publish","type":"post","link":"https:\/\/www.codingbroz.com\/python-program-to-check-if-a-number-is-positive-negative-or-zero\/","title":{"rendered":"Python Program to Check If a Number is Positive, Negative or Zero"},"content":{"rendered":"\n

In this post, we will learn how to check whether a number is positive, negative or zero using Python<\/strong> Programming language.<\/p>\n\n\n\n

This program asks the user to enter a number, then it will check whether the entered number is positive<\/strong>, negative or zero<\/strong> using the following approaches:<\/p>\n\n\n\n

  1. Using If. . .Else Statement<\/li>
  2. Using Nested List<\/li><\/ol>\n\n\n\n

    So, without further ado, let\u2019s begin this tutorial.<\/p>\n\n\n\n

    \n