My Profile

Wednesday, January 26, 2011

System.Console.WriteLine

In Console applications, we use this line in every program. So, let's discuss about this in detail.


Console is a predefined class under the base class libraries which provide some standard IO functionalities that can be performed on standard IO devices.


It provides few static methods in it like Write, WriteLine, ReadLine etc.,


System is a namespace where a namespace is a logical container of types ( class or structure or interface etc ).
It is used for performing core operations.


We use namespace for two different reasons, those are:



  • Grouping of related types.
  • To overcome the naming collision i.e., Multiple classes with same name can be defined by putting them under a separate namespace.
fig: Namespace Demo




----------------------------------------------------------

** If you like this post please like our page in facebook "Dot Net Support

0 comments:

Post a Comment

Share

Twitter Delicious Facebook Digg Stumbleupon Favorites More