google.com, pub-4617457846989927, DIRECT, f08c47fec0942fa0 Learn to enjoy every minute of your life.Only I can change my life.

Tuesday, July 8, 2014

Call by value and Call by refrence

Explain call by value and call by reference with example.

Call by value-
When a function call is given, a relationship is established between actual and formal parameters.
A temporary storage is created for formal parameters to store the data(actual parameters) received
as input from calling function. This process of data transfer from actual parameter to formal
parameters is known as call by value.

Ex: void main()
{ int a=20,b=30,x;
int f1(int,int);
-----
x=f1(a,b);
-----
getch( );
}
int f1(int p, int q)
{
p=p+p;
q=q+q;
return(p+q);
}

Call by reference-
When a function is called, the address of variables are passed on to the
called function. The parameters receiving the address should be pointer variables. This
concept of sending the address of data from calling function to pointer variables in the
called function is known as call by reference.

Ex: viod main()
{
int a=10,b=15,c=20;
------
X=f1(&a,&b,&c);
------
getch();
}
int f1(int *p1, int  *p2, int  *p3)
{
*p1=*p1+10;
*p2=*p2+5;
}

More on Networking


Network services
File Services-All the data files of an organisation are stored in one place and can be
shared by many users. Files can be organized and updated systematically.
Print Services- When Printers available on the Network , multiple users can print to
the same printer. The network printers are usually faster and more capable. They
may have accessories such as envelope readers or multiple paper trays
Database Services-Multiple users can have access to the database at the same time.
The Database software ensures integrity of data and provides multiple access.
Message Services-The services include Electronic mail, voice mail, remote
access,document transfers across the internet.
Application services- several software applications that are developed using
network architecture. The applications can be made available to multiple users. Any
up-gradation made to these applications is also instantly available to the users.

Advantages of Computer Network
Speed:- The files can be transferred from one Computer to another instantly.
Cost:- Application software(Network version) can be installed on one Computer and
accessed by other Computers on the Network. This makes maintenance and
upgrading of software easy.
Security:- The information on the computer can bemade available only through
password.Further some information can be made available only for reading and
not copying.
Resource sharing:- Expensive peripheral devices can be shared by many users in a
network.
Easy access:- Users can access information from any computer that is available on
the network. They need go to a specific Computer which may be located in a
different building or different location to retrieve information from their account.

अच्छे विचार करे विचार

  पहचान की नुमाईश, जरा कम करें... जहाँ भी "मैं" लिखा है, उसे "हम" करें... हमारी "इच्छाओं" से ज़्यादा "सुन...