answersLogoWhite

0

What else can I help you with?

Continue Learning about Engineering

What are the limitations of friend function?

Only that they cannot be inherited by derived classes. This is "a good thing". Other than that, a friend function has full access to a class' private and protected members and you cannot limit its scope.


Which variable is not destroyed on exit from the function instead its value is presented and becomes available again when the function is next called These variables are declared as?

Local function variables defined static remain in memory at all times. Such variables are only in scope (accessible) when the function itself is in scope.


Can you assign your scope to subroutione in perl ex like this my sub fun name....definition of function...?

Yes, in Perl, you can assign a scope to a subroutine using the my keyword to declare variables within the subroutine, allowing them to be scoped locally to that subroutine. For example: sub fun { my $local_var = "I'm local"; # This variable is scoped to the subroutine print $local_var; } This keeps $local_var from being accessible outside of fun, ensuring encapsulation within the subroutine.


How are the keywords struct and class different?

The keyword class is not a keyword in C. It is a keyword in C++, so I have added C++ to the category list for this question.The default access specifier for struct is public, while for class, it is private.Struct does not allow you to specify methods, while class does.A struct is not a class, and cannot be derived, while a class can be treated as a struct, if the scope and access is correct.


What are the limitations of friend function in c plus plus?

Only that they cannot be inherited by derived classes. This is "a good thing". Other than that, a friend function has full access to a class' private and protected members and you cannot limit its scope. At this data hiding feature of c++ is broken.

Related Questions

Which is the keyword used to limit the scope of the function to the file in which it is reside?

Declare the function static.


What are the limitations of friend function?

Only that they cannot be inherited by derived classes. This is "a good thing". Other than that, a friend function has full access to a class' private and protected members and you cannot limit its scope.


What are the scope and limitation of illegal logging?

all i know is that scope mean "nasasakupan" and limitation is "limit"


Meaning scope and role of marketing function in exchange process with suitable examples?

scope and role of marketing function in the exchange process


Scope of static variables?

Scope of static variable is with in the file if it is static global. Scope of static variable is with in the function if variable is declared local to a function. But the life time is throughout the program


Is a muzzleloading scope and a rifle scope the same thing?

They perform the same function, but, they are not the same.


What are the limitations of functionalism?

Only that they cannot be inherited by derived classes. This is "a good thing". Other than that, a friend function has full access to a class' private and protected members and you cannot limit its scope.


What is the scope of a static function in C?

The source file it is in.


What are synonyms for compass?

range, field, area, reach, scope, limit, extent, boundary


What factors should be considered when determining the scope of a research project, and how can the keyword research for the project be effectively conducted?

When determining the scope of a research project, factors to consider include the research question, available resources, time constraints, and the desired outcomes. To effectively conduct keyword research for the project, start by brainstorming relevant terms, using online tools like Google Keyword Planner, analyzing competitor keywords, and refining the list based on relevance and search volume.


What is the purpose of including the keyword "what is" in the introduction of a research paper?

The purpose of including the keyword "what is" in the introduction of a research paper is to clearly define and introduce the topic or concept that will be discussed in the study. It helps to establish the focus and scope of the research, guiding readers on what to expect in the paper.


Which variable is not destroyed on exit from the function instead its value is presented and becomes available again when the function is next called These variables are declared as?

Local function variables defined static remain in memory at all times. Such variables are only in scope (accessible) when the function itself is in scope.