Question
Complete the class EmailAccount1 that implements the EmailAccount interface. In addition to the requirements explicitly stated in the interface, note the following: The integers used
Complete the class EmailAccount1 that implements the EmailAccount interface. In addition to the requirements explicitly stated in the interface, note the following:
The integers used in email addresses follow the standard OSU naming strategy. That is, the smallest positive integer that makes an address unique is used. For example, if the first two email accounts instantiated are for Alice Scarlet and Bob Gray, both would have a "1" in their email address since the last names are sufficient to distinguish them. Only if a second account with a last name of Scarlet (or Gray) is instantiated would a "2" be used for the new account's email address.
It is possible to have several people with the same last name (e.g., Alice Scarlet and Jane Scarlet) and even several people with the same full name (e.g., three Bob Gray accounts, each getting its separate email address gray.1, gray.2, and gray.3).
The names provided to the constructor can use arbitrary case (e.g., Scarlet or SCARLET or ScArLeT). Whatever case was used by the client should be used in the strings returned by name and toString. However, the email address should only include lower case letters.
Numbers that have been used previously for some email address cannot be reused for the same last name.
emailaccount1.java: http://web.cse.ohio-state.edu/software/2231/web-sw2/assignments/homeworks/email-accounts/EmailAccount1.java
emailaccount.java: http://web.cse.ohio-state.edu/software/2231/web-sw2/assignments/homeworks/email-accounts/EmailAccount.java
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started