What is the difference between struct and class?
Structs are value type whereas Classes are reference type. Structs are stored on the stack whereas Classes are stored on the heap. Value types hold their value in memory where they are declared, but reference type holds a reference to an object memory.
Is This Answer Correct ? | 0 Yes | 0 No |
what is static function
How long it will take to learn c++?
What is the use of typedef?
What is a "Copy Constructor"?
What does '\r' and '\b' mean? Please explain with example.
how to create window program in c++.please explain.
Define macro.
What is the difference in size of this two clasees? Class A { int a; char c; float f; } Class B { float f; char c; int a; }
Difference between struct and class in terms of access modifier.
Problem 5: Hero's Formula is A method for calculating the area of a triangle when you know the lengths of all three sides. Let a, b, c be the lengths of the sides of a triangle. The area is given by:A= pp-ap-b(p-c) | wherep= a+b+c2 | | Write a C-language code to calculate area of triangle using above method. Take the three lengths of the triangle from the user and display the area that your program calculates.
What happens if an exception is throws from an, object's constructor and object's destructor?
What are the important differences between c++ and java?