>
#software-development
,
#programming-help
>
Write c++ program ask the user to enter password program should asking for password until user enter tcorrect once the correct password entered print access granted and terminate loop else invalid?
Write c++ program ask the user to enter password program should asking for password until user enter tcorrect once the correct password entered print access granted and terminate loop else invalid?
In this program, the correct password is set to "password123". The program will keep asking the user to enter a password until the correct password is entered. If the user enters the correct password, the program will print "Access granted" and terminate the loop. If the user enters an incorrect password, the program will print "Invalid password. Try again." and continue to ask for the password.