Created
December 30, 2016 06:59
-
-
Save yukkura/747387680352590947b316595b6556d4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# UTF-8で保存して実行して下さい. | |
# 真と偽についての確認用プログラム | |
# 数値型 | |
if 0: | |
print(0) | |
if 1: | |
print(1) | |
if 10: | |
print(10) | |
if 0.0: | |
print(0.0) | |
if 1.0: | |
print(1.0) | |
# 文字列型 | |
if "": | |
print("") | |
if "Hello World": | |
print("Hello World") | |
if 'Hello World': | |
print('Hello World') | |
# Boolean型 | |
if True: | |
print(True) | |
if False: | |
print(False) | |
# リスト | |
if []: | |
print([]) | |
if [1, 2, 3, 4]: | |
print([1, 2, 3, 4]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment