Explain the terms constructors and destructors, Computer Engineering

Assignment Help:

When we initialize the form at that time if we require to set any variable's value then we can set it by defining in constructor. Constructor's name always similar as class name and destructor is used to recover memory occupied by any variable important in constructor. Constructor and destructor is the new method in object oriented languages to initialize the variables at the time of object creation.

When we declare an object, we can pass the values to it and that values will be assigned to the data members of that class, whose object it is. A class can have no. of objects & no. of constructors. A constructor is called automatically when an object is formed. There is only one destructor in any class, that is to deallocated the memory of the object when an object is cracked or no longer exist  

 


Related Discussions:- Explain the terms constructors and destructors

Digital forensics, a) What do you meant by digital forensics? b) What ...

a) What do you meant by digital forensics? b) What is the job of Computer Forensic Analyst c) From the point of view of : i. An employer ii. An employee Give thre

Explain fundamental models of inter process communication, Explain the two ...

Explain the two fundamental models of inter process communication. Two kinds of message passing system are given as: (a) Direct Communication : Along with direct communicat

Define bandwidth, Define Bandwidth? When transferring blocks of data, i...

Define Bandwidth? When transferring blocks of data, it is of interest to know how much time is required to transfer an entire block, as blocks can be variable in size it is use

Backward chaining, Backward Chaining: In generally given that we are o...

Backward Chaining: In generally given that we are only interested in constructing the path whether we can set our initial state to be the theorem statement and search backward

Programming in c, Write a program to find the area under the curve y = f(x)...

Write a program to find the area under the curve y = f(x) between x = a and x = b, integrate y = f(x) between the limits of a and b. The area under a curve between two points can b

Line of code of assembly language, In how many ways line of code of assembl...

In how many ways line of code of assembly language can be divided? A line of code of an assembly language program can be divided in three columns called as fields. The fields d

K-nearest neighbor for text classification, Assignment 2: K-nearest neighbo...

Assignment 2: K-nearest neighbor for text classification. The goal of text classification is to identify the topic for a piece of text (news article, web-blog, etc.). Text clas

What a hardware uses to calculates cyclic redundancy check, Hardware that c...

Hardware that calculates CRC (Cyclic Redundancy Check) uses: Hardware which computes CRC utilizes shift register and Xor unit.

Explain the transport layer in detail, Explain the transport layer in detai...

Explain the transport layer in detail. Transport Layer: The transport layer controls and makes sure the end-to-end integrity of the data message propagated by the network am

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd