Advertisement
Captainctc

Untitled

Feb 20th, 2020
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.34 KB | None | 0 0
  1. #a program to check the truthy or falsiness of a number
  2. show = 1
  3. def truthy_or_falsy(number): #function definition
  4.    if number: #check for condition one
  5.       return "the value" + " " + str(number) + " "+ "is truthy"
  6.    else:
  7.       return "the value" + " " + str(number) + " " + "is falsy"
  8. print(truthy_or_falsy("")) #final output print out
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement