Define local classes, C/C++ Programming

A class can be defined inside a block or function.  This type class is known local class. There are few points to be observed when producing class inside the function or block.

·     Local class can use access global variable with scope operator (::).

·     Local class cannot remain static data member.

·     Local class member function must be defined inside its class that is it can have only inline function.

Posted Date: 9/20/2012 8:03:56 AM | Location : United States







Related Discussions:- Define local classes, Assignment Help, Ask Question on Define local classes, Get Answer, Expert's Help, Define local classes Discussions

Write discussion on Define local classes
Your posts are moderated
Related Questions
Control Flow The control flow statements are used when it is needed that the flow of the program is to be changed after taking some decision. This control flow statement theref


find area uder the curve y=f(x) between x=a and x=b

Write a program that illustrate  Macros with Arguments? Macros is able to also have arguments, just as functions can. #define AREA(x)(3.14*x*x) Then at any time the prepr

A: Use operator overloading to present a friend right-shift operator, operator>>. It is similar to the output operator, except the parameter doesn't contain a const: "Fred&" instea

In this lab, please complete a given program to perform the following tasks: 1. Allocate a 10 by 5 2D byte array dynamically. The way of allocation must be consistent with pag

A Padovan string P(n) for a natural number n is defined as: P(0) = ‘X’ P(1) = ‘Y’ P(2) = ‘Z’ P(n) = P(n-2) + P(n-3), n>2 where + denotes string concatenation. For a string of t

Project Description: I have software written with VB that i helped design, but now the original author died,(Neil Tromp), and the software ended up in the hands of someone else!

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.

create a program to populate the first array then the odd number is the second array and get the sum of the second array.