i don't know, how to get my vocabulary take in windows
import pygame,random,time,sys
print (" TỪ ĐIỂN CỦA HUY")
database = {
#A
'at''\t\t':'Tại\t',
'as''\t\t' :'Như\t',
'and''\t\t' :'Và\t',
'age''\t\t' :'Tuổi tác\t',
'ask''\t\t' :'Hỏi\t',
'any''\t\t' :'Bất kì\t',
'aunt''\t\t':'Cô\t',
'area''\t\t':'Khu vực, địa điểm\t',
'auto' '\t\t':'Tự động\t',
'alow' '\t\t':'Ôi chao\t',
'about' '\t\t':'Khoảng\t',
'After' '\t\t':'Sau đó\t',
'among' '\t\t':'Ở giữa\t',
'along' '\t\t':'Dọc theo\t',
'alone' '\t\t':'Một mình\t',
'adult' '\t\t':'Trưởng thành\t',
'apple' '\t\t':'Quả táo\t',
'angry' '\t\t':'Tức giận\t',
'admit' '\t\t':'Thừa nhận\t',
'actor' '\t\t':'Diễn viên\t',
'angel''\t\t':'Thiên thần\t',
'around''\t\t':'Xung quanh\t',
'always''\t\t':'Luôn luôn\t',
'amount''\t\t':'Số tiền\t',
'appear''\t\t':'Suất hiện\t',
'advice''\t\t':'Lời khuyên\t',
'author''\t\t':'Tác giả\t',
'acting''\t\t':'Diễn xuất\t',
'another''\t\t':'Khác\t',
'against''\t\t':'Chống lại\t',
'already''\t\t':'Sẵn sàng\t',
'ability''\t\t':'Có khả năng\t',
'average''\t\t':'Trung bình cộng\t',
'account''\t\t':'Tài khoản\t',
'article''\t\t':'Bài báo\t',
'assumed''\t\t':'Giả định\t',
'acquired''\t\t':'Mua\t',
'adminstration''\t\t':'Sự quản trị\t',
'accomplishement''\t\t':'Thành quả\t',
'apocalypticism''\t\t':'Thuyết khải huyền\t',
'accountability''\t\t':'Trách nhiệm\t',
'afforestrations''\t\t':'Trồng rừng\t',
'accommodations''\t\t':'Chỗ ở\t',
'atherosclerosis''\t\t':'Xơ vữa động mạch\t',
'anticompetitive''\t\t':'Phản cạnh tranh\t',
'apprenticeships''\t\t':'Học việc\t',
'acknowledgments''\t\t':'Sự nhìn nhận\t',
'available''\t\t':'Có sẵn\t',
'assistant''\t\t':'Phụ tá\t',
'afternoon''\t\t':'Buổi chiều\t',
'advantage''\t\t':'Lợi thế\t',
'analytics''\t\t':'Phân tích\t',
'allowance''\t\t':'Trợ cấp\t',
'apartment''\t\t':'Căn hộ\t',
'anonymous''\t\t':'Vô danh\t',
'accompany''\t\t':'Đồng hành\t',
'accounting''\t\t':'Kế toán\t',
'assessment''\t\t':'Thẩm định, lượng định, đánh giá\t',
'acceptance''\t\t':'Chấp thuận\t',
'assistance''\t\t':'Hỗ trợ\t',
'atractive''\t\t':'Hấp dẫn\t',
'appearance''\t\t':'Xuất hiện\t',
'affordable''\t\t':'Giá cả phải chăng\t',
'adaptation''\t\t':'Sự thích nghi\t',
'ammnunition''\t\t':'Đạn dược\t',
'accommodate''\t\t':'Cung cấp, chứa đựng\t',
'advertising''\t\t':'Quảng cáo\t',
'anniversary''\t\t':'Kỉ niệm\t',
'advencement''\t\t':'Thăng tiến\t',
'attribution''\t\t':'Sự biểu hiện, sự tượng trưng\t',
'aggravation''\t\t':'làm tăng thêm\t',
'assemblyman''\t\t':'Người trong hội đồng\t',
'aquaculture''\t\t':'Nuôi trồng thủy sản\t',
'announcement''\t\t':'Sự thông báo\t',
'architecture''\t\t':'Ngành kiến trúc\t',
'appreciative''\t\t':'Đánh giá cao\t',
'articulation''\t\t':'Sự khớp nối\t',
'appendicular''\t\t':'Hình thấu kính\t',
'adminstrator''\t\t':'Người quản lí\t',
'advertisement''\t\t':'Quảng cáo\t',
'appropriation''\t\t':'Chiếm đoạt\t',
'authoritarian''\t\t':'Độc tài\t',
'administrated''\t\t':'Quản lí\t',
'air change rate''\t\t':'Định mức thay đổi không khí\t',
'air conditioner''\t\t':'Máy điều hòa không khí\t',
'air curtain''\t\t':'Màn không khí nóng\t',
'air filter''\t\t':'Bộ lọc không khí\t',
'air handing unit''\t\t':'Thiết bị quạt lớn thổi không khí luân chuyển trong nhà\t',
'air vent''\t\t':'Ống thông gió\t',
'air washer''\t\t':'Thiết bị làm sạch không khí bằng tia nước phun hạt nhỏ\t',
'attenulator''\t\t':'Thiết bị làm giảm ồn truyền theo không khí lạnh\t',
'addtional''\t\t':'Thêm vào\t',
'action''\t\t':' Hành động\t',
'application':'Ứng dụng\t',
'although''\t\t':'Mặc dù\t',
'approach''\t\t':'Tiếp cận\t',
'actually''\t\t':'Thực ra\t',
'anything''\t\t':'Bất cứ điều gì\t',
'activity''\t\t':'Họat động\t',
'attention''\t\t':'Chú ý\t',
'achieved''\t\t':'Đã đạt được\t',
'accepted''\t\t':'Chấp thuận\t',
}
#Tạo thanh công cụ
def show_menu():
print("---------------------------------------")
print("- TỪ ĐIỂN OFFLINE -")
print("---------------------------------------")
#show menu
print(" Chọn phím số để thực hiện tuần tự thao tác")
print("--------------------------------------------")
print(" [1] Search vocabulary : ")
print(" [2] Show all vocabulary : ")
print(" [0] Out app ")
print("--------------------------------------------")
show_menu()# đưa menu ra
#Tìm kiếm từ vựng
def find():
word = input("+ Bạn cần tìm từ gì: ")
if word in database:
print("Tìm thấy: _ %s: %s " % (word, database[word] ))
else:
print("Không tìm thấy từ [ %s ]" % word) and choice == 0
def viewall():
print("_ XEM TẤT CẢ TỪ VỰNG")
for word, mean in database.items():
print("_%s:%s" %(word, mean))
#Chương trình gốc
choice = int(input("Mời chọn chức năng để tiếp tục thực hiện: "))
#tạo giao diện cửa sổ
win = pygame.display.set_mode((900,500))
pygame.display.set_caption('Giao diện cửa sổ')
while True:
pygame.time.delay(200)
for event in pygame.event.get():
if event.type == pygame.QUIT:
pygame.QUIT()
print(pygame())
while choice != 0:
if choice == 0:
break
elif choice == 1:
find()
elif choice == 2:
viewall()
break
else:
print(" Không có lựa chọn hoặc chưa lập trình :D ")
choice = int(input (" Bạn muốn thực hiện hành động gì"))
print("Hẹn gặp lại")
Voters