Knowee
Questions
Features
Study Tools

DescriptionYou need to create a Constructor function which will create object for Student details of the following properties:name: It will store student nameroll_no: Stores the roll numberclass: Stores the classsection: Stores the sectionmarks_of_5_subjects: It will store marks of science, maths, social science, english & hindi. You can store marks in this format:{ science: 72, maths: 75, social_science: 79, english: 80, hindi: 67}printTop3Subjects: It is a function method. It will print top three subject names based on marks.printReportCard: It is also a function method. It will create and print a report card of a student. For example:+--------------------+| REPORT CARD |+--------------------+| Name - Huzaifa || Roll no. - 16 || Class - X || Section - A || Science - 73 || S.Sc - 79 || Maths - 75 || English - 80 | | Hindi - 67 || Prectage - 74.8 % |+--------------------+

Question

DescriptionYou need to create a Constructor function which will create object for Student details of the following properties:name: It will store student nameroll_no: Stores the roll numberclass: Stores the classsection: Stores the sectionmarks_of_5_subjects: It will store marks of science, maths, social science, english & hindi. You can store marks in this format:{ science: 72, maths: 75, social_science: 79, english: 80, hindi: 67}printTop3Subjects: It is a function method. It will print top three subject names based on marks.printReportCard: It is also a function method. It will create and print a report card of a student. For example:+--------------------+| REPORT CARD |+--------------------+| Name - Huzaifa || Roll no. - 16 || Class - X || Section - A || Science - 73 || S.Sc - 79 || Maths - 75 || English - 80 | | Hindi - 67 || Prectage - 74.8 % |+--------------------+

...expand
🧐 Not the exact question you are looking for?Go ask a question

Solution

I'm sorry, but you didn't provide any text for me to respond to. Could you please provide the text?

Similar Questions

DescriptionYou need to create a Constructor function which will create object for Student details of the following properties:name: It will store student nameroll_no: Stores the roll numberclass: Stores the classsection: Stores the sectionmarks_of_5_subjects: It will store marks of science, maths, social science, english & hindi. You can store marks in this format:{ science: 72, maths: 75, social_science: 79, english: 80, hindi: 67}printTop3Subjects: It is a function method. It will print top three subject names based on marks.printReportCard: It is also a function method. It will create and print a report card of a student. For example:+--------------------+| REPORT CARD |+--------------------+| Name - Huzaifa || Roll no. - 16 || Class - X || Section - A || Science - 73 || S.Sc - 79 || Maths - 75 || English - 80 | | Hindi - 67 || Prectage - 74.8 % |+--------------------+

Create a class called "Student" with private member variables for name, roll number, and marks in three subjects. Include public member functions to set the student details, calculate the average marks, and display the student detail

Create a class named 'Student' with a string variable 'name' and an integer variable 'roll_no'. Assign the value of roll_no as '2' and that of name as "John" by creating an object of the class Student.

. Design a class for a student who has details, such as id, name and email. The class has method Show() which prints the details of the student. Create one object of the class and initialize the object with details at the time of initialization. Create another object and give the default detail to the object. Perform constructor overloading and method overloading in the class.

2. A Course, Getters, and SettersmandatoryImplement a class named HolbertonCourse:Constructor attributes:name (String)length (Number)students (array of Strings)Make sure to verify the type of attributes during object creationEach attribute must be stored in an “underscore” attribute version (ex: name is stored in _name)Implement a getter and setter for each attribute.bob@dylan:~$ cat 2-main.jsimport HolbertonCourse from "./2-hbtn_course.js";const c1 = new HolbertonCourse("ES6", 1, ["Bob", "Jane"])console.log(c1.name);c1.name = "Python 101";console.log(c1);try { c1.name = 12;} catch(err) { console.log(err);}try { const c2 = new HolbertonCourse("ES6", "1", ["Bob", "Jane"]);}catch(err) { console.log(err);}bob@dylan:~$ bob@dylan:~$ npm run dev 2-main.js ES6HolbertonCourse { _name: 'Python 101', _length: 1, _students: [ 'Bob', 'Jane' ]}TypeError: Name must be a string ...TypeError: Length must be a number ...bob@dylan:~$

1/3

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.