I have a text file having the following design:
FirstName= xxxxx
LastName= xxxxx
Username= qwerty
Password= qwerty100
Email ID= xx@gmail.com
PhoneNumber= 12345678
____________
FirstName= yyyyy
LastName= yyyyy
Username= qwerty999
Password= pass100
Email ID= yy@gmail.com
PhoneNumber= 1235326
I have the task to code a login/signup program.The above text is generated by the signup form.The sign up program asks the user to input user name and password and if it matches any of the username with its corresponding password, the user successfully logs in with a successfully logged in message on the terminal
For example: If the user inputs username: qwerty999 and password: pass100, the program shows a successfully logged in message and if no database is found matching the user input, a error message is displayed and the program terminates
My main problem is that I cannot search for the input username and password input by the user in the text file. I want it to be searched and store in another variable which the program can compare with the user input