I'm learning Python, and this program worked fine, but suddenly i got a red line from the : at line 33 to the end of the program, with the error "illegal target for annotation". How could i fix this?
import turtle
import decimal
from decimal import Decimal
import sys
account_1_name = "John Smith"
account_1_balance = "67.58"
account_1_vault_balance = "200.00"
style = ('Calibri', 30)
password = input("What is your password?")
if password == "Cryptic":
turtle.hideturtle()
turtle.bgcolor("green")
turtle.write("Access Granted.", font=style)
turtle.done()
prompt = input("""
Welcome to Bank Network.
Hello, %s
Your balance is $%s
Your savings account balance is $%s.
type transfer to transfer money to savings section.
type deposit to deposit a check.""" % (account_1_name, account_1_balance , account_1_vault_balance))
if prompt == "deposit":
print("deposit system is down right now. Please try again later.")
sys.exit(0)
if prompt == "transfer":
transfer_amount = input("How much do you want to transfer?")
transfer_prompt = input("""
are you sure you want to transfer money to your savings section?
type cancel to cancel.
type confirm to transfer"""
if transfer_amount > account_1_balance:
print("Not enough balance.")
if transfer_amount < account_1_balance:
print("Ok. Money transfered.")
balance_post_transfer = Decimal(account_1_balance) - Decimal(transfer_amount)
account_1_vault_balance_post_transfer = Decimal(account_1_vault_balance) + Decimal(transfer_amount)
print("Your balance is now $%s and your savings account balance is $%s" % (balance_post_transfer, account_1_vault_balance_post_transfer))
if password != ("Cryptic"):
turtle.hideturtle()
print("access denied.")
turtle.bgcolor("red")
turtle.write("access denied.", font=style)
turtle.done()