Create a class College and Faculty. Create at least 3 objects of each class and display all details using generic method display
Question
Create a class College and Faculty. Create at least 3 objects of each class and display all details using generic method display
Solution
Sure, here is a simple example in Python:
class College:
def __init__(self, name, location, established):
self.name = name
self.location = location
self.established = established
def display(self):
print(f"College Name: {self.name}, Location: {self.location}, Established: {self.established}")
class Faculty:
def __
Similar Questions
Construct a class Person with attributes name, age, address and a methoddisplay() to display the details. Create a subclass Student with attributesrollno, mark1, mark2, and mark3. Override display() method and calculatethe grade. Create another subclass Faculty with attributes faculty_id,department, basic_pay and DA. Override display() method to calculate totalsalary as (basic_pay + DA) + 70% of (basic_pay + DA). Create instances ofStudent and Faculty and display the details
t a university, 3 courses are offered: "Programming", "Databases" and "Software Engineering".Each course is offered by a lecturer.Create for each course an instance of type COURSE (=class) using a constructor (parameters: name of the course and the lecturer).The lecturer is stored in a data member of type LECTURER (=class). The class LECTURER should have at least the data member academic_title.The courses have a maximum of 10 and a minimum of 3 course participants.The courses can be attended not only by our own students, but also by students from other universities.The class STUDENT should have at least the following data members: Matriculation numberUniversityStudents from their own university may take any course.Students from other universities may only take one course.The classes LECTURER and STUDENT should derive from the class PERSON.The class PERSON should have at least the following data members:SurnameFirst nameEmailTask: Create a program with a menu that covers the following situation:1. Registration for a course (including querying student data). Each student has a unique email, meaning there can't be two or more students with the same email in the same course.2. Output of one/all courses with data of the participants. Please note that if there are fewer than 3 participants in a course, an additional message must be displayed - "Course will not take place".3. Output of all courses that are not fully booked yet. The output must include the number of free places, the name of the course and the academic name of the lecturer with its academic title.4. End of program: A message will be displayed stating which participants (=all data members of the class PERSON) have to be notified because your course is not taking place.If necessary (creation, search, and so on), corresponding messages are to be displayed.Permanent storage of the data is not required. The data must only be available at the runtime of the program.Use comments in the source code to document your program.
Design a class named Person and its two subclasses named Student and Employee. Make Faculty and Staff subclasses of Employee. A person has a name, address, phone_number, and e-mail address. A student has a status (freshman, sophomore, junior, or senior). An employee has an office, salary. A faculty member has office_hours and a rank. A staff member has a title. Override the toString() method in each of these classes to display their details. Write a Java application and subsequent pseudocode to implement/simulate the same.
Consider a Faculty Management System implemented in Java. The system allows users to input details for multiple faculties, including their name, designation, the number of courses they handle, and the courses they handle. Users can then filter and display faculties based on the number of courses they handle. Sample Input: Enter the number of faculties: 2 Enter details for faculty 1:Name: JaiDesignation: PCourses Handled: 2Enter course 1: JavaEnter course 2: DBMS Enter details for faculty 2:Name: SakthiDesignation: APCourses Handled: 3Enter course 1: PythonEnter course 2: JavaEnter course 3: DBMS Enter the number of courses to filter faculties: 3 Sample Output: SakthiAP3OS Python Java
Problem Statement:Your university wants you to create a management system that will store employee data in the following hierarchy. Create the necessary classes that represent the following diagram: The attributes for each of the classes are provided in the diagram for your reference.In addition to the Staff, Management, and the Teacher classes, you need to create the Education class which should be associated only with the Teacher and the Management.You have to create a menu based application to store and display the data.The input options shall be 1 for Teacher, 2 for Management, and 3 for Admin.For each of these options you display the type of data being provided as input and request the user to enter the relevant information. For qualification, you shall provide them with options from 1-4 and once all the data has been provided, you shall then display the given information in a formatted output.Once the data has been displayed, you should then print "Staff being deleted..." in the Staff class's destructor.Please refer to the input and output section for more details.Input format :The input consists of an integer choice, followed by data related to a specific employee type (Teacher, Management, or Admin) based on the given choice.For Teacher:choice = 1Employee code (string)Employee name (string)Educational qualification (integer): (1: - Undergraduate, 2 - Graduate, 3 - Masters Degree, 4 - PhD)Subject (string)For Management:choice = 2Employee code (string)Employee name (string)Educational qualification (integer): (1: - Undergraduate, 2 - Graduate, 3 - Masters Degree, 4 - PhD)Management Grade (float)For Admin:choice = 3Employee code (string)Employee name (string)Department (string)Output format :The output displays the user information based on the user input, along with the "Staff being deleted..." message from the destructor.A new line space is given after the last line of the output.Refer to the sample output for the formatting specifications.Code constraints :The educational qualification should only be within the given range of 1 to 4The choice will be an integer between 1 and 3 (inclusive).Employee code, employee name, subject, and department will be strings with a maximum length of 20 characters.Educational qualification will be an integer (1, 2, 3, or 4).Management Grade should be an integer.Sample test cases :Input 1 :1ABC3343HarryPotter2WizardryOutput 1 :TEACHER The given information:Employee code: ABC3343Employee name: HarryPotterEducational Qualification: GraduateSubject: WizardryStaff being deleted...Staff being deleted...Staff being deleted...Input 2 :2KLD34RonWeasley34Output 2 :MANAGEMENT The given information:Employee code: KLD34Employee name: RonWeasleyEducational Qualification: Masters DegreeManagement Grade: 4Staff being deleted...Staff being deleted...Staff being deleted...Input 3 :3CMS34343HermioneCompsciOutput 3 :ADMIN The given information:Employee code: CMS34343Employee name: HermioneDepartment: CompsciStaff being deleted...Staff being deleted...Staff being deleted...Input 4 :4Output 4 :Invalid choiceStaff being deleted...Staff being deleted...Staff being deleted...Input 5 :2KLD34RonWeasley6532Output 5 :MANAGEMENTInvalid Educational Qualification. Try one more time.Invalid Educational Qualification. Try one more time. The given information:Employee code: KLD34Employee name: RonWeasleyEducational Qualification: Masters DegreeManagement Grade: 2Staff being deleted...Staff being deleted...Staff being deleted...Note :The program will be evaluated only after the “Submit Code” is clicked.Extra spaces and new line characters in the program output will result in the failure of the test case.
Upgrade your grade with Knowee
Get personalized homework help. Review tough concepts in more detail, or go deeper into your topic by exploring other relevant questions.