Maurice Tutor

(5)

$15/per page/Negotiable

About Maurice Tutor

Levels Tought:
Elementary,Middle School,High School,College,University,PHD

Expertise:
Algebra,Applied Sciences See all
Algebra,Applied Sciences,Biology,Calculus,Chemistry,Economics,English,Essay writing,Geography,Geology,Health & Medical,Physics,Science Hide all
Teaching Since: May 2017
Last Sign in: 408 Weeks Ago, 6 Days Ago
Questions Answered: 66690
Tutorials Posted: 66688

Education

  • MCS,PHD
    Argosy University/ Phoniex University/
    Nov-2005 - Oct-2011

Experience

  • Professor
    Phoniex University
    Oct-2001 - Nov-2016

Category > Management Posted 07 Jul 2017 My Price 15.00

Implement a dynamic Login System

Implement a dynamic Login System for our CIS14 Computer Labs. Assuming there are 4 computer labs (Lab#1-#4) in our R Building on campus, each lab having 10 computers (Computer #1-10):

Lab#1: 10 computers

Lab#2: 10 computers

Lab#3: 10 computers

Lab#4: 10 computers

The user can log into any available ONE computer with any ID that is 5 ASCII characters long (e.g., “Ab231”, “!pas!”, “ab00~”, etc). Logout is only possible with the exact spelling of the ID in the system.

 

To begin the user is presented with the following SELECTION MENU with the 4 options:

login_selection.png

In this assignment, you are asked to implement a LoginSystem class as follows:

 

class LoginSystem {

// 2D array holding Lab#s and corresponding Computer#s

string** labs;

public:

LoginSystem();

~LoginSystem();

void showStatus();

void showMenu();

void login();

void logout();

void search();

void quit();

};

 

Grading for this assignment is broken down into how you implement each of the following elements of your Login System and the correctness of your end result for each element. Please pay attention to your Syntax/Logic for each element. Efficiency is NOT graded but your logic is.

Grading Rubrics:

- (3 Points) main()

- (3 Points) LoginSystem()

- (3 Points) ~LoginSystem()

- (3 Points) void showStatus()

- (3 Points) void showMenu()

- (4 points) void login()

- (4 points) void logout()

- (4 points) void search()

- (2 points) void quit()

- (1 Point) Styling/Documentation

===============================

Total: 30 Points

 

(3 Points) Implementation for main():

• Create your LoginSystem instance• Invoke showStatus() and showMenu()• Enable selection of the 4 menu choiceslogin_main.png

(3 Points) LoginSystem()

• Dynamic allocation of your 2D array, labs

(3 Points) ~LoginSystem()

• Dynamic de-allocation of your 2D array, labs

 

(3 Points) void showStatus()

• This function prints the status of all Lab#/Computer# slots as follows
• When a Lab#/Computer# slot is available, not in use, the program displays the string “empty” for that slot
• When a Lab#/Computer# slot is taken the program prints the user ID occupying that slot
• Initially when no one is logged in all Lab#/Computer# slots should be empty:

login_showstatus.png

(3 Points) void showMenu()

• This function prints all available user options, namely, LOGIN, LOGOUT, SEARCH, and QUIT as follows:login_selection.png

 

(4 points) When LOGIN is selected:

• The program prompts “Enter your 5-character ID to login: ”• The program checks whether the ID contains any 5 ASCII characters• If not the program repeats the prompt "Enter your 5-character ID to login:” until it receives ID containing 5 ASCII characters.Note "empty" is not a valid ID• If yes the program proceeds to the next prompt• After a valid ID is received the program prompts “Enter the Lab #: “• The program checks whether the Lab # is a number between 1-4• If not the program repeats the prompt "Enter the lab #:" until it receives a valid Lab #• If yes the program proceeds to the next prompt• After a valid Lab # is received, the program prompts “Enter the Computer #: “• The program checks whether the Computer # is a number between 1-10• If not the program repeats the same prompt "Enter the Computer #:" until it receives a valid Computer #• If yes the program proceeds to the next step• The program checks to see if the computer has already been used. If so the program displays "ERROR, user [ID] is already logged into that station."
• The program checks to see if the user has already logged in elsewhere. If so the program prints "User [ID] is in Lab #[LAB_NUM], Computer #[COMP_NUM]” where [ID] is the user ID, and [LAB_NUM] and [COMP_NUM] are the actual lab and computer numbers that the user is associated with. See the example below.
• If not the program proceeds to the next step• After everything is entered, at the end of the LOGIN process, the program invokes both showStatus() and showMenu()

login_loginselected.png

login_user_same_location.png

login_login_user_exists.png

(4 Points) When LOGOUT is selected:

• The program prompts "Enter your 5-character ID to logout:”• The program checks whether the ID contains any 5 ASCII characters• If not the program repeats the prompt "Enter your 5-character ID to logout:” until it receives a valid ID. Note "empty" is not a valid ID• If yes the program proceeds to the next validation:• If the valid ID is received but not found in your 2D array data structure, the program prompts “That user is not logged in.”• If the valid ID is found in your 2D array data structure the program prints “User [ID] is logged out” where [ID] is the user entered ID such as 12345 in the following example• At the end of the LOGOUT process the program invokes showStatus() and showMenu()

login_logoutselected.png

(4 points) When SEARCH is selected:

• The program prompts “Enter a 5-character ID to search:”• The program checks whether the ID contains any 5 ASCII characters. Note "empty" is not a valid ID• If not the program repeats the prompt "Enter a 5-character ID to search:"until it receives a valid ID• If yes the program proceeds to the next validation:• If a valid ID is received but not found in your 2D array data structure, the program prompts “That user is not logged in.”• If the ID is found in your 2D array data structure the program prints “User [ID] is in Lab #[LAB_NUM], Computer #[COMP_NUM]” where [ID] is the user ID, and [LAB_NUM] and [COMP_NUM] are the actual lab and computer numbers that the user is associated with. See the example below.• At the end of the LOGOUT process the program invokes showStatus() and showMenu()

login_searchselected.png

 

(2 points) When QUIT is selected:

• The program exits, de-allocating all of the dynamic memory in use

Answers

(5)
Status NEW Posted 07 Jul 2017 09:07 PM My Price 15.00

Hel-----------lo -----------Sir-----------/Ma-----------dam----------- ----------- -----------  -----------  ----------- T-----------han-----------k Y-----------ou -----------for----------- us-----------ing----------- ou-----------r w-----------ebs-----------ite----------- an-----------d a-----------cqu-----------isi-----------tio-----------n o-----------f m-----------y p-----------ost-----------ed -----------sol-----------uti-----------on.----------- Pl-----------eas-----------e p-----------ing----------- me----------- on----------- ch-----------at -----------I a-----------m o-----------nli-----------ne -----------or -----------inb-----------ox -----------me -----------a m-----------ess-----------age-----------

Not Rated(0)