-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbook_app.py
More file actions
36 lines (26 loc) · 856 Bytes
/
book_app.py
File metadata and controls
36 lines (26 loc) · 856 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import os
import time
import csv
import platform
with open("./books.csv",encoding="utf8") as fp:
books=list(csv.reader(fp))
return
def get_return():
time.sleep(1)
return input("メニューに戻ります >> Enterキー")
def get_confirm():
while True:
x=input("以上でよろしいでしょうか?( yes / no )
if x in ['y','yes','Y','Yes','YES']:
return True
elif x in ['n','no','N','No','NO']:
return False
else:
print("yes / no どちらかを入力してください。")
def clear_screen():
# ターミナルコマンドを入力するメソッド 画面クリア
if platform.system()=="Windows":
os.system('cls')
else:
os.system('clear')
def int_check(value,string):