import mysql.connector

try:
    conn = mysql.connector.connect(database="cookbook",
                                   host="localhost",
                                   user="root",
                                   password="<PASSWORD>")
    print("Connected")
except:
    print("cannot connect to server")




import mysql.connector

try:
    conn = mysql.connector.connect(database="cookbook",
                                   host="localhost",
                                   user="root",
                                   password="<PASSWORD>")
    print("Connected")
except:
    print("cannot connect to server")



