Krystor 0 Newbie Poster

Hello everybody!
Today i am writing a program to connect usées without database, with only one function:
createaccount(username,password)
That you must write on the beginning if the program.
But i don't know how to finish it, with the "connect" function :

class User():
    def init(self, inputusername="a", inputpassword="b"):
    self.username = str(inputusername)
    self.password = str(inputpassword)

def createaccount(user,pw):
    user = User(user,pw)

def connect(userinput,pwinput):
    what?

def loadaccounts():
    createaccount("user1","mypw")
    createaccount("testuser","testpassword")

def askuser():
    while True:
        user = droid.dialogGetInput("User","Entrez votre nom d'utilisateur").result
        pw = droid.dialogGetPassword("Password","Entrez votre mot de passe").result
        if connect(user,pw) == True:
            print("ok")
            break
        else:
            break

I am french, and so my program is. Don't Give attention to the "droid" text, it is just the interface , made with android module.
Thanks for helping me.