"using namespace std" --> it specify that we want to use whole namespace named* std .*
In std namespace varous objects like cout, cin ,endl etc are define if we donot use std namespace then we have to explicitly specify name namespace in which particular objects are defined eg. std::cout<<"hello world "; std::cin>>x; etc * for more deatils about namespaces read chapter 10 part 1 (thinking in C++ by bruceckel , very nice explanation ) * On Tue, Oct 9, 2012 at 8:52 PM, rishabh singh yadav < rishirocker.sing...@gmail.com> wrote: > namespaces allows us to group a set of global classes, objects and/or > functions under a name. If you specify *using namespace std* then you > don't have to put *std::* throughout your code. > > > On Tue, Oct 9, 2012 at 7:46 PM, rahul sharma <rahul23111...@gmail.com>wrote: > >> That i know..please tell me its use and need >> >> >> On Tue, Oct 9, 2012 at 12:05 AM, Abhishek Patro <agbpa...@gmail.com>wrote: >> >>> if u have seen the iostream file then it begins like this:- >>> >>> #include <bits/c++config.h> >>> #include <ostream> >>> #include <istream> >>> * >>> * >>> *namespace std * >>> { >>> /** >>> * @name Standard Stream Objects >>> * >>> * The <iostream> header declares the eight <em>standard stream >>> * objects</em>. For other declarations, see >>> * http://gcc.gnu.org/onlinedocs/libstdc++/27_io/howto.html#10 and >>> the >>> * @link s27_2_iosfwd I/O forward declarations @endlink >>> * >>> * They are required by default to cooperate with the global C >>> library's >>> * @c FILE streams, and to be available during program startup and >>> * termination. For more information, see the HOWTO linked to above. >>> */ >>> //@{ >>> extern istream cin; ///< Linked to standard input >>> extern ostream cout; ///< Linked to standard output >>> extern ostream cerr; ///< Linked to standard error (unbuffered) >>> >>> The new implementation is done in C# format. So we use the term "using" >>> to include the iostream "package". >>> >>> >>> >>> On Tue, Oct 9, 2012 at 12:01 AM, rahul sharma >>> <rahul23111...@gmail.com>wrote: >>> >>>> using name space std >>>> >>>> Please explain about this >>>> thnx >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "Algorithm Geeks" group. >>>> To post to this group, send email to algogeeks@googlegroups.com. >>>> To unsubscribe from this group, send email to >>>> algogeeks+unsubscr...@googlegroups.com. >>>> For more options, visit this group at >>>> http://groups.google.com/group/algogeeks?hl=en. >>>> >>> >>> >>> >>> -- >>> Abhishek Patro >>> >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "Algorithm Geeks" group. >>> To post to this group, send email to algogeeks@googlegroups.com. >>> To unsubscribe from this group, send email to >>> algogeeks+unsubscr...@googlegroups.com. >>> For more options, visit this group at >>> http://groups.google.com/group/algogeeks?hl=en. >>> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Algorithm Geeks" group. >> To post to this group, send email to algogeeks@googlegroups.com. >> To unsubscribe from this group, send email to >> algogeeks+unsubscr...@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/algogeeks?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Algorithm Geeks" group. > To post to this group, send email to algogeeks@googlegroups.com. > To unsubscribe from this group, send email to > algogeeks+unsubscr...@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/algogeeks?hl=en. > -- *RAHUL KUMAR DUBEY* *BTech-3rd year * *Computer Science &Engineering * *Motilal Nehru National Institute Of Technology* *Allahabad[211004],UP.* -- You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to this group, send email to algogeeks@googlegroups.com. To unsubscribe from this group, send email to algogeeks+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/algogeeks?hl=en.