prasadsawant7 / Python_Programs

This repo is made for Hacktober Fest open source contributions. Anyone who wants to contribute to open source they can contribute here (Only Python Codes).
3 stars 21 forks source link

feat/issue-39 - print positive numbers in a list #50

Closed rafaeldias97 closed 1 year ago

rafaeldias97 commented 1 year ago

Title

A python program that print positive numbers in a list Issue #39

Code Example

# Python program to print positive numbers in a list
# List of numbers
listNumbers = [0, -10, 21, 4, -45, -66, 93, -11]

# Iterating each number in list
for num in listNumbers:

    # checking condition
    if num >= 0:
        print(num)