Ask Question, Ask an Expert

+1-415-315-9853

info@mywordsolution.com

Ask C/C++ Expert


Home >> C/C++

Answer the following problems

problem1)  

Describe the term Class and Object using ex of a student class. Student class represents name, enrolment number, father’s name, telephone number, programme code and date of birth of a student. The class has the function to illustrate the information about student except date of birth, and to modify information of telephone number and programme. Name the private and public members (data members as well as member functions) for the class student. Define the data types of member variables using C++ and create few objects of the class. Could you put information in those objects? Give reasons.                                    

problem2)                            

Describe the following terms in context of object oriented programming using student class of problem 1. You should use C++ to define student class. Additionally, suppose that student class has a sub class namely “PhD Student” who has the extra field “Department”. The function to describe the information about PhD student also prints department in addition to showing information as shown by the student class.                             

(a) Overloaded Constructors

(b) Encapsulation

(c) Inheritance

(d) Polymorphism

problem3)    

prepare down the advantages of using UML? Create class diagram for a University having classes – Student, Teacher, Subject and Programme. Make appropriate assumptions, if any.

problem4)

Describe the usage of the following C++ operators with the help of the ex program.

(a) operator for type casting

(b) operator for bitwise OR

(c) operator for dereferencing an address

(d) comma operator

problem5)  

Differentiate between call by value and call by reference with the help of an ex in content of function call. Describe the advantages of call by value. What does C++ uses?         

problem6)

prepare down the template class “binaryTree” in C++. The class must have functions for search and insert and element into a binaryTree. Use this template to make a binary tree of integer keys. Make appropriate assumptions, if any.            

problem7)   

Create a class AlphaString which stores only alphabets in a string of arbitrary length. String has a constructor which ensures that String has only Alphabets. Class also has the copy constructor, and an overloaded + operator. The overloaded + operator must perform concatenation of two strings. Does the class need an explicit destructor? Justify your answer.

C/C++, Programming

  • Category:- C/C++
  • Reference No.:- M92360

Have any Question? 


Related Questions in C/C++

Assignmentgoals developing problem-solving skills declaring

Assignment Goals: Developing problem-solving skills, declaring variables, multi-way branches, data validation. Problem: Complete Programming Challenge 4.19 in your text book. Do not accept values larger than 10 meters or ...

The second portion instruction shown below which is the

The second portion (instruction shown below) which is the actual C++ program is needed by this Saturday. Write a C++ program that is menu-driven that allows for the following menu choices:Load an exam: Loading an exam sh ...

Projectdecision statementsdirections read carefully and

Project: Decision Statements Directions (Read CAREFULLY and follow COMPLETELY): - Create the following programs in C++ that perform the purpose described and show the sample output (with user input where applicable). - I ...

Computer applications divisionassignment c programmingstl

COMPUTER APPLICATIONS DIVISION Assignment: C++ PROGRAMMING STL Vector For this assignment, you will be starting with an example program that demonstrates the use of a STL vector. In addition to this, you may need to look ...

1 three employees in a company are up special pay increase

1. Three employees in a company are up special pay increase. You are given a file, with the following data: Miller Andrew 65789.87 5 Green Sheila 75892.56 6 Sethi Amit 74900.50 6.1 Each input line consists of an employee ...

Programming cc assignmentsyoull need to download this to

Programming C/C++ assignments You'll need to download this To write the program. The programs will be written using the Microsoft Visual C++ Express Edition IDE (Integrated Development Environment), which can be download ...

Assignmentwhen writing c programs include comments in your

Assignment When writing C++ programs include comments in your code, make the program readable by indenting, use meaningful variable and function names, and produce meaningful output. This assignment will be to write a te ...

Practice with pointers and dynamic memory

Practice with pointers and dynamic memory allocation Problem: Write a C++ program that will implement and test the four functions described below that use pointers and dynamic memory allocation. The Functions: You will w ...

Assignmentthis assignment gives you the opportunity to

Assignment This assignment gives you the opportunity to practice array of pointers, linked lists and self referential structures. Write a program that initializes two parallel arrays as follows: char * String[] = { "Abbi ...

Assignment a random mazewrite a new c program with the

Assignment (a) Random Maze Write a new C++ program with the following functionality: The program writes a greeting on the screen. Then the program displays a maze of ASCII symbols on the screen. The maze consists of 8 ro ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Section onea in an atwood machine suppose two objects of

SECTION ONE (a) In an Atwood Machine, suppose two objects of unequal mass are hung vertically over a frictionless

Part 1you work in hr for a company that operates a factory

Part 1: You work in HR for a company that operates a factory manufacturing fiberglass. There are several hundred empl

Details on advanced accounting paperthis paper is intended

DETAILS ON ADVANCED ACCOUNTING PAPER This paper is intended for students to apply the theoretical knowledge around ac

Create a provider database and related reports and queries

Create a provider database and related reports and queries to capture contact information for potential PC component pro

Describe what you learned about the impact of economic

Describe what you learned about the impact of economic, social, and demographic trends affecting the US labor environmen