小编use*_*051的帖子

什么是“ AttributeError: '_io.TextIOWrapper' object has no attribute 'replace' ”在python中?

print (
"""    Welcome to the code breaker game!
       In this game you will have to change symbols into letters in order to decipher secret words. 
       0 - instructions
       1 - start
       2 - clues
       3 - check your answers
       4 - quit
""")

choice = input(" choice : ")

if choice == ("0"):
    text_file = open ("instructions.txt","r")
    print (text_file.read())
    text_file.close()

elif choice =="1":
    text_file = open ("words.txt","r")
    contents = text_file
    print (text_file.read())
    text_file.close()
    a = input("Please enter a symbol …
Run Code Online (Sandbox Code Playgroud)

python attributes

5
推荐指数
1
解决办法
2万
查看次数

标签 统计

attributes ×1

python ×1