Giter Site home page Giter Site logo

employee-management-cpp's Introduction

Employee Management System

A simple C++ program for managing employee!


Features:

1. Add Employee with Details such as Name, Age, ID, Designation, Salary 2. Display All Employees 3. Search Employee 4. Modify Employee 5. Delete Employee

The code first creates a vector called employees to store the employee data. The Employee structure is used to store the Employee data. It has the following members:

name: The employee's name
age: The employee's age
id: The employee's ID
designation: The employee's designation
salary: The employee's salary

The addEmployee() function adds an employee to the employees vector. It takes the employee's name, age, ID, designation, and salary as input and stores them in the Employee structure. The employee is then added to the employees vector.

The displayEmployees() function displays all the employees in the employees vector. It iterates through the vector and prints the employee's name, age, ID, designation, and salary.

The searchEmployee() function searches for an employee in the employees vector by ID. It takes the employee's ID as input and iterates through the vector. If the employee's ID is found, the employee's information is printed. If the employee's ID is not found, a message is printed stating that the employee was not found.

The modifyEmployee() function modifies an employee's record in the employees vector. It takes the employee's ID as input and iterates through the vector. If the employee's ID is found, the employee's information is updated with the new information. If the employee's ID is not found, a message is printed stating that the employee was not found.

The deleteEmployee() function deletes an employee from the employees vector. It takes the employee's ID as input and iterates through the vector. If the employee's ID is found, the employee is removed from the vector. If the employee's ID is not found, a message is printed stating that the employee was not found.

The code also has a main function that allows the user to interact with the employee management system. The user can add employees, display employees, search for employees, modify employees, and delete employees.

I hope this explanation is helpful. Please let me know if you have any other questions.

employee-management-cpp's People

Contributors

akshat162001 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.