Question: Write a program that creates usernames for new email addresses: Create two variables, one that stores your first name ( as a String ) and
Write a program that creates usernames for new email addresses:
Create two variables, one that stores your first name as a String and another that stores the last digits of your student number as an integer Print them.
Using selection statements, check if the length of your first name is greater than characters
If it is longer than square root the student number variable and cast it to an integer.
If it is less than or equal to divide the student number variable by and then square the number using a Math method
Finally, concatenate your first name, the resulting student number, and @algomau.ca Print this final email address in the console to report it to the user.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
