Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Employee Database Your Program Must: Load the employees from the provided file o They must be stored in a map, where the key is the

Employee Database

Your Program Must:

Load the employees from the provided file o They must be stored in a map, where the key is the username of the employee and the value is the data for the employee

Give the user an interface to log in with a username and password o If it matches one of the entries from the file, output the data for that user o If it does not match, show an error message

If a user logs in and isManager for their profile is set to true: o

Employee Struct

struct Employee

{

char username[50]; char password[50]; int id;

char fullname[70]; double salary; bool isManager;

};

Show a list of all employees

Log logins and failed login attempts to a file named access.log o The existing contents of the file should be preserved between runs of the program

image text in transcribed

Example Input and Output elcome to the employee management system! Username: Password: jdoe passwd User found Your Profile: User ID: 101 Name: John Doe Salary: $650e0 Username: Password: mgarcia qwertyu Listing all employees: User ID: 152 Username: dsmith ame: David Smith Salary: $70000 User ID: 338 Username: imartinez Name: Isabella Martinez Salary: $65000 User ID: 101 Username: jdoe Name: John Doe Salary: $656e0 User ID: 32e Username: jjohnson ame: Ji11 Johnson Salary: $60000 User ID: 214 Username: mgarcia Name: Mary Garcia Salary: $80000 User ID: 321 Username: msmith Name: Mark Smith Salary: $55000

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_2

Step: 3

blur-text-image_3

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

Main Memory Database Systems

Authors: Frans Faerber, Alfons Kemper, Per-Åke Alfons

1st Edition

1680833243, 978-1680833249

Students also viewed these Databases questions

Question

Discuss the techniques of job analysis.

Answered: 1 week ago

Question

How do we do subnetting in IPv6?Explain with a suitable example.

Answered: 1 week ago

Question

Explain the guideline for job description.

Answered: 1 week ago

Question

What is job description ? State the uses of job description.

Answered: 1 week ago

Question

What are the objectives of job evaluation ?

Answered: 1 week ago