انشاء نظام بلغة c++ باستخدام السجلات لادخال ببانات 10 موظفين مع ارقامهم ورواتبهم مع امكانية اختيار المستخدم ويظهر للمستخدم رسائل توضحية للاختيار 1- دالة ادخال البيانات للموظفين في السجلات 2- دالة طباعة بيانات الموظفين من السجلات 3- دالة للبحث عن موظف داخل السجلات 4- دالة للبحث عن اكبر قيمة داخل السجلات 5- دالة لترتيب الموظفين حسب اكبر راتب
#include <iostream> #include <string> using namespace std; struct employee{ string name; int salary; int id; }; void menu(){ cout << "1- Enter Employees" << endl; cout << "2- Print Employees" << endl; cout << "3- Search By ID" << endl; cout << "4- Search By Salary" << endl; cout << "5- Search By Name" << endl; cout << "6- Quit" << endl; } void EnterEmployee(employee employeeList[], int i){ cout << "Name: "; cin >> employeeList[i].name; cout << "Salary: "; cin >> employeeList[i].salary; cout << "ID: "; cin >> employeeList[i].id; } void printEmployees(employee EmployeeList[], int i){ cout << "Name: " << EmployeeList[i].name