Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a function to check whether a user is validuser 5 pass 5 When a particular user is going to login , program will ask

Write a function to check whether a user is validuser5
pass5
When a particular user is going to login, program
will ask for user-id and password and that will be
matched with stored user-id and password from
that predefined array.
If the given user-id and password is: "userl" and
"pass I" and no. of digits that will be used to
generate token is 3,
then the output message should be
"Welcome user 1 and the generated token is:
token-101" where "token-101" is the token
generated based on first N digit Palindrome
number concatenated with "token" string literal
value.
A palindromic number (also known as a numeral
palindrome or a numeric palindrome) is a
number (such as 16461) that remains the same
when its digits are reversed. In other words, it
has reflectional symmetry across a vertical axis.
Thetarm nalindmmicic derivad fram nalindinma
user or not. If user is valid user then a welcome
message should display with a token number.
Token number will be generated based on first
palindrome number of N digits.
If the user is not valid user then the function
should display "UserId or password is not valid,
pls try again.".
All valid User-id and password should be stored
in an array like below :-
When a particular user is going to login, program
will ask for user-id and password and that will be
matched with stored user-id and password from
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And SQL For DB2

Authors: James Cooper

1st Edition

1583473572, 978-1583473573

More Books

Students also viewed these Databases questions