ソースコード
#coding:utf-8
#object string 文字列オブジェクト
import time
import os
os.system("clear")
hello = "hello world!"
print(type(hello),hello)
input("次へ")
a = "こんにちは、よい一日を "
print(type(a),a)
b='''
.--~~,__
:-....,-------`~~'._.'
`-,,, ,_ ;'~U'
_,-' ,'`-__; '--.
(_/'~~ ''''(;'''
print(type(b),b)
c='''
|\_/| **************************** (\_/)
/ @ @ \ * "Purrrfectly pleasant" * (='.'=)
( > º < ) * Poppy Prinz * (")_(")
`>>x<<´ * (pprinz@example.com) *
/ O \ ****************************
'''
print(type(c),c)
input("次へ")
#縦に表示
for x in a:
print(x)
time.sleep(1)
print("\n")
input("次へ")
#横に表示
str1=""
for x in a:
str1 += x
print("\r"+str1,end="")
time.sleep(1)
print("\n")
input("次へ")
#複数行文字列の表示
os.system("clear")
str = ""
for x in b:
str += x
print("\r\033[8A"+str,end="")
time.sleep(0.05)
print("\n")
os.system("clear")
str = ""
for x in c:
str += x
print("\r\033[11A"+str,end="")
time.sleep(0.05)
print("\n")