Question 2: Consider the following code and write the complete definition of the mentioned class according to the code written in the main program? Moreover, write additional code in the main program to display details for the employee with the highest salary. class private: public: }; int main() { Employee el("E1000”, “AHMAD", "100000"); //ecode, ename, esalary Employee e2 (el); el.display();
Q: Proving yourself worthy of being able to handle bigger tasks, the tech lead has decided to give you…
A: 1. The MySQL query for the given problem is as follows: CREATE TABLE employees ( employee_id…
Q: Some databases employ just the magnetic disc's outer tracks, leaving the inner tracks unused. Hot…
A: GIVEN: Some databases written on magnetic discs only access data from the disk's outer tracks,…
Q: One may search memory via direct or sequential access. Both access methods work. How is rapid access…
A: Direct access data is read instantaneously rather than needing to be reread from the beginning. By…
Q: Which firewall function is more important? How should packet-filtering software be used?
A: Put out the firewall system's objective. NOTE: We'll start with the first one as you posed many…
Q: File manager? Explain Windows Explorer. Include certain file storage and storage areas.…
A: Based on the facts provided; We must discuss Windows Explorer and the file manager. Windows has a…
Q: Is a size m hash table's linked list count constant? I'm clueless about hash functions. Demonstrate…
A: The linked list count in a hash table is not necessarily constant and can vary depending on the data…
Q: Discuss the GRANT statement's consequences on intellectual property rights. What rewards may one…
A: Introduction: For the sake of accessing database items, it is used to provide privileges to a…
Q: Why should you care about EPROM, EEPROM, and Flash Memory differences? What does a parity bit do?
A: EPROM (Erasable Programmable Read Only Memory) is optically read and written: EPROMs must have the…
Q: It may be easier to understand an operating system's resource allocator role with an example.…
A: A resource allocator is the Operating System.
Q: Q8. You are now more sure about your choice. You still wish to broaden your horizon, but you also…
A: A database view is a subset of a database and is based on a query that runs on one or more database…
Q: While discussing data, what are the potential legal repercussions of the issues raised?
A: Introduction The world today runs on data, and as such, data has become a valuable asset for…
Q: To recognise multiprocessor systems, one needs to understand how system components interact.…
A: A multiprocessor system is a computer system that has multiple processors or CPUs that can work…
Q: Despite wired networks being quicker, both forms of networks provide the fastest speeds. What…
A: The statement "both forms of networks provide the fastest speeds" is a bit ambiguous, so I'll…
Q: wo methods may terminate operations and resolve impasses:
A: A deadlock occurs when two computer programs that share the same resource effectively prevent each…
Q: You are going to create an autogenerated list of numbers. Ask a user for a random number between…
A: Note : You have not mention the language of the program so i'm answering your question in Python.…
Q: The following is a concise summary of the three-sphere systems management paradigm. Is there any way…
A: System Management: The three-sphere system management approach addresses the business,…
Q: Web and database keyword searches vary greatly. What are the main differences between query…
A: Web and database keyword searches vary greatly in terms of search strategies and techniques…
Q: Multiprocessor systems may be categorised by their interactions.
A: Introduction: Currently, multiprocessor systems are efficiently used to improve the performance of…
Q: A chat with you may lead to a discussion of security incidents involving access control or…
A: Launch: A data/security breach happens when confidential or protected information is compromised. A…
Q: A clarification of the meaning of the word "model" in relation to System Analysis Determine the key…
A: Introduction: Model: Models simplify complex concepts. It helps to understand, analyze, and predict…
Q: What apps use dynamic programming?
A: In this question we have to understand what apps use dynamic programming? Let's understand and hope…
Q: Today's businesses need social media. CIOs struggle to engage workers on social media.
A: Your difficulties with social networking sites Computing the Investment Return Developing a strategy…
Q: Describe Dynamic Web development environment?
A: In this question we need to explain the concept of Dynamic Web development environment.
Q: Provide instances of Phantom and Dirty's criminal activities.
A: Phantom criminal activities: It occurs when two indistinguishable criminal activities are…
Q: A super wing-ding diagnostic tool on your computer found that your hard disc, CPU, RAM, and graphics…
A: According to the information given:- We have to define a super wing-ding diagnostic tool on your…
Q: What is the key difference between non-proactive scheduling and preemptive scheduling? Provide…
A: The key difference between non-proactive scheduling and preemptive scheduling is in how they handle…
Q: Discuss the application domain of the implications of blockchain technology?
A: Generally speaking, Blockchain technology is a decentralized system which is allowing the multiple…
Q: In the context of the development of computer systems, it is important to make a distinction between…
A: Introduction Computer System: A computer system is a collection of hardware, software, and data that…
Q: Which company firewall arrangement is most popular? Why? Explain.
A: A network firewall is a device that filters network traffic for cybersecurity purposes. The…
Q: How can I safely detach a 250 GB solid state disc from a computer without affecting the running…
A: Your answer is given below.
Q: What are some examples of successful collaboration between software developers and their end users?
A: Successful collaboration between software developers and end users is essential for creating…
Q: Discuss mobile device versus cloud computing relevance. Cloud computing offers mobile device growth…
A: Mobile devices and cloud computing are both important technologies in today's world, and they each…
Q: What are the pros and cons of each iteration of networking technology?
A: Networking technology The hardware, software, and protocols used to build and manage computer…
Q: Wireless networks influence developing nations. Why aren't LANs and other physical connections being…
A: A wireless network is a type of computer network that transmits data between the many nodes that…
Q: Provide instances of Phantom and Dirty's criminal activities.
A: A dirty read occurs when a transaction is allowed to access data from a row that has been changed…
Q: What does "Access Point" imply for WiFi? Have you considered future steps?
A: A wireless access point (wireless AP) is a network device that connects a fixed wire network and a…
Q: How can a routing table be set up on each router in the most time- and resource-effective manner?
A: Setting up a routing table on a router in the most time- and resource-effective manner involves the…
Q: What kinds of information are taken in and given out by this university-based management information…
A: A management information system is a system designed o study people, technology, and organisations…
Q: It's possible that the amount of free space on a hard disc is affected by how often live backups are…
A: RAID, The RAID : Redundant Array of Independent Disks (RAID) is a data storage virtualization system…
Q: Which strategies are the most successful when it comes to controlling your firewall? Explain.
A: Given: Best firewall management practises? Explain. Firewall management best practises: Block…
Q: Why should you distinguish EPROM, EEPROM, and Flash Memory? Parity bits' purpose?
A: Introduction: EPROM is another kind of ROM that may be read and written by optical means (Erasable…
Q: A mouse push event precedes a mouse click.
A: Yes, a mouse push event typically precedes a mouse click event. When you use a computer mouse to…
Q: How do you define a new data source?
A: Defining a new data source depends on the type of data you want the data source to be. Here are the…
Q: How are solid-state disks (SSDs) in business PCs different from those in laptops?
A: Solid-state disks used in business PCs tend to have higher capacity,durability,and may use…
Q: What are the reasons for the prevalence of magnetic tape as a medium for the storage of information?
A: Introduction Magnetic Tape: Magnetic tape is a medium for storing digital data on a thin, flexible…
Q: An unintegrated information system may cause several challenges.
A: INTRODUCTION: An information system (IS) is a group of different pieces of equipment that work…
Q: Being a global virtual company, GM faces several ethical issues. Richard Mason discovered four.…
A: Given: In 1997, Vyakarnam et al. conducted research on businesses with less than 20 employees. They…
Q: Why not provide people a number of different alternatives when it comes to storing their XML data?
A: XML is an excellent option for storing data in many situations. It is simple to read and write. It…
Q: What separates computer ethics, IP, copyright, and patent in the business context?
A: The study of what is morally right or wrong, just or unjust, falls under the purview of ethics,…
Q: Compare abstraction to computer science examples. Software engineering is a good example of…
A: Abstraction is a concept that is widely used in computer science and software engineering to manage…
OOPs
In today's technology-driven world, computer programming skills are in high demand. The object-oriented programming (OOP) approach is very much useful while designing and maintaining software programs. Object-oriented programming (OOP) is a basic programming paradigm that almost every developer has used at some stage in their career.
Constructor
The easiest way to think of a constructor in object-oriented programming (OOP) languages is:
C----------insk.
Step by step
Solved in 4 steps with 2 images
- Question 2: Consider the following code and write the complete definition of the mentioned class according to the code written in the main program? Moreover, write additional code in the main program to display details for the employee with the highest salary. class { private: public: int main ( ) { Employee el(“E1000", “AHMAD", “100000"); l/ecode, ename, esalary Employee e2 (el); el.display( );3. Person and Customer Classes The Person and Customer Classes Write a class named Person with data attributes for a person’s name, address, and telephone number. Next, write a class named Customer that is a subclass of the Person class. The Customer class should have a data attribute for a customer number, and a Boolean data attribute indicating whether the customer wishes to be on a mailing list. Demonstrate an instance of the Customer class in a simple program.Question 2: Consider the following code and write the complete definition of the mentioned class accordingto the code written in the main program? Moreover, write additional code in the main program to displaydetails for the employee with the highest salary.class {private:public:};int main ( ) {Employee e1(“E1000”, “AHMAD”, “100000”); //ecode, ename, esalaryEmployee e2 (e1);e1.display( );}
- Language: C++ Create a class named City. Assume that a city has a name, a number of inhabitants, a mayor and an area (in km²). Then create three instances of this class: Bremen, Paris and London. Provide suitable setter and getter methods for each of these properties. The class declaration has to be placed into City.h, the class definition has to be placed into City.cpp and the test program where the instances are created has to be in testcity.cpp. You can set the needed data from the main () function by initialization or read it from the key- board.•Person Class: Person class has attributes: String name, address and int age. Write setperson() function to set values and getPerson() to Print attributes. Also write appropriate constructors.•Employee Class: Write another class Employee having attributes department and salary of type string and double. Write methods setEmployee(), getEmployee() and appropriate constructors for Employee class.•Student Class:•Write a class Student having attributes registration number and GPA of type string and float. Also write setStudent(), getStudent() methods and required constructors. Use the concept of inheritance to achieve the above functionality. Write a main() function to display the information of employee and student.• Note: Call the constructors/methods of parent class in child class where required in java code•Person Class: Person class has attributes: String name, address and int age. Write setperson() function to set values and getPerson() to Print attributes. Also write appropriate constructors. •Employee Class: Write another class Employee having attributes department and salary of type string and double. Write methods setEmployee(), getEmployee() and appropriate constructors for Employee class. •Student Class: •Write a class Student having attributes registration number and GPA of type string and float. Also write setStudent(), getStudent() methods and required constructors. Use the concept of inheritance to achieve the above functionality. Write a main() function to display the information of employee and student. • Note: Call the constructors/methods of parent class in child class where required
- Complete the code for the following program. You are provided with an abstract class called abst. Create a class that will be a child of abst and it will be called usesAbst. Your program will have an int variable called value, and all the appropriate methods, as well 2 constructors. The first constructor will simply set the variable value to 0. The second constructor will set the variable value to equal a passed in parameter. You do not have to comment your code. public abstract class abst{ public abst () { } //Outputs to the screen the message Hello public abstract void sayHello (); //returns the stored int value public abstract int getValue (); //sets the int value to x public abstract void setValue (int x); //Outputs to the screen the message Another method public void output () { System.out.println("Another method"); public String tostring () { return "This is an abstract class"; }Write in python. Write a class named Employee that has **private** data members for an employee's name, ID_number, salary, and email_address. It should have an init method that takes four values and uses them to initialize the data members. It should have get methods named get_name, get_ID_number, get_salary, and get_email_address.Write a separate function (not part of the Employee class) named **make_employee_dict** that takes as parameters a list of names, a list of ID numbers, a list of salaries and a list of email addresses (which are all the same length). The function should take the first value of each list and use them to create an Employee object. It should do the same with the second value of each list, etc. to the end of the lists. As it creates these objects, it should add them to a dictionary, where the key is the ID number and the value for that key is the whole Employee object. The function should return the resulting dictionary.For example, it could be used like…Write c# equivalent statements for the following: There is a book library. Define classes respectively for a library. The library must contain a name and a list of books (use array). The books only contain author name as information. In the class, which describes the library, create methods to add a book to the library, to search for a book by a predefined author, and to delete a book from the library. Write a test class, which creates an object of type library, adds several books to it. Implement a test functionality, which finds all books authored by Stephen King and deletes them. Finally, display information for each of the remaining books.
- Write a class Runner having three private data members (distance, minutes, seconds) The class has A constructor which having no parameter – for setting values to zero or null.Getters/setters for data members.Write a function show() which displays the“The player covered “+distance+ “ in “ +minutes +” minutes , and “ + seconds+” seconds”; Write test Application that demonstrates the above class by calling all the methods, creating a Create 3 Runner objects, input values and then display the record of winner.in javaProblem: Create a base class called Vehicle that has the manufacturer’s name (typeString), number of cylinders in the engine (type int), and the owner (type Person). Use thePerson class developed this semester. Create a class automobile that is derived fromVehicle and has additional properties: number of passengers (type int) and weight in tons(type double). Create a class Truck which is derived from Vehicle and has additionalproperties: the load capacity in tons (type double, since it may contain a fractional part)and towing capacity in tons (type double). The classes should have:• Two constructors, a default and an overloaded constructor• All appropriate accessor and mutator methods (getters and setters).• An ‘equals’ method (must conform to the Person example and the Object class ).• A ‘toString’ method• A ‘copy’ constructor• A ‘clone’ method• A ‘finalize’ method Write a driver (client/test) class that tests ALL the methods. Be sure to invoke each of the constructors, and ALL…Problem: Create a base class called Vehicle that has the manufacturer’s name (typeString), number of cylinders in the engine (type int), and the owner (type Person). Use thePerson class developed this semester. Create a class automobile that is derived fromVehicle and has additional properties: number of passengers (type int) and weight in tons(type double). Create a class Truck which is derived from Vehicle and has additionalproperties: the load capacity in tons (type double, since it may contain a fractional part)and towing capacity in tons (type double). The classes should have:• Two constructors, a default and an overloaded constructor• All appropriate accessor and mutator methods (getters and setters).• An ‘equals’ method (must conform to the Person example and the Object class ).• A ‘toString’ method• A ‘copy’ constructor• A ‘clone’ method• A ‘finalize’ method Write a driver (client/test) class that tests ALL the methods. Be sure to invoke each of the constructors, and ALL…