Problem Solving with C++ (10th Edition)
Problem Solving with C++ (10th Edition)
10th Edition
ISBN: 9780134448282
Author: Walter Savitch, Kenrick Mock
Publisher: PEARSON
Question
Book Icon
Chapter 12.2, Problem 10STE
Program Plan Intro

Namespace:

  • Namespace is a group of name definitions such as definition of class and declaration of variable.
  • Generally, the namespace in C++ is used in the ways of “std” namespace. The “std” namespace contains each and every name defined in the standard library files that user use such as “iostream” and “sdtdlib”.
  • If the user do not place the code in some exact namespace, then the code in a namespace known as the global namespace.
    • The global namespace does not contain a “using” directive because users are continuously using the global namespace.
  • Consider a name that is defined in two namespaces. When the user tends to use the namespaces that are defined that is if the user uses both namespace, then the resultant that is obtained will contain error in it.

Blurred answer
Students have asked these similar questions
For the following function headers, determinethe number, and datatype of each parameterthat must be passed to the function. What is the return type on the function listed below? int factorial (int n) Number of parameters: Parameter types: double volts (int res, double induct, double cap) Number of parameters: Parameter types:
Write a function prototype and function header for a function called compute. The function should have 3 parameters: an int, a double and a long. The int parameter should have a default argument of 5, and the long parameter should have a default argument of 65536. The double parameter should have no default arguments. The parameters no necessarily in the order.
When a function can take another function as a parameter, how can type-checking occur?
Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
C++ for Engineers and Scientists
Computer Science
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Course Technology Ptr
Text book image
C++ Programming: From Problem Analysis to Program...
Computer Science
ISBN:9781337102087
Author:D. S. Malik
Publisher:Cengage Learning