how to swap all the values without using temporary variable.
tha values r a = 20, x=60 and p=2.
Answers were Sorted based on User's Feedback
Answer / padmas
To swap the values without using temporary variable
for a,x and p,
Do a call to swap function for a and p and
another call to same swap function for x and p.
call1:swap(a,p);
call2:swap(x,p);
swap(variable1,variable2)
{no temporary variable}
Is This Answer Correct ? | 2 Yes | 1 No |
Answer / padmas
If the values for a=20,x=60, and p=2 then
need another set of values for b=,y= and q= to do the swap
without using temporary variable.
Is This Answer Correct ? | 1 Yes | 2 No |
Why we use NEW operator when we create Object,While in C++ we donot ?
Can anyone send me NIC question papers alongwith answers on nidhi1485@yahoo.co.in? Urgently needed.. Thanks in advance
what is class module in vb6? what it's use? with example..
Difference of Console, web & windows applications?
how to convert the data from HTML file to SAS dataset?
what is difference between restoring and non restoring division?
code for connection from windows forms to sql server
How to connect to ms word wit VB ojective is to prepare s/w to generate question paper , selects questions randomly from the ms access , database
the systematic access of small computers in a distributed data processing system is referred as?
Can i please VHDL code for D-Latch with clear input ?? (HINT: Set up a “Process” with appropriate sensitivity list to get the desired D-Latch with Clr working.) Inputs and Outputs: entity Lab4b is Port ( Clr, Clk, D : in STD_LOGIC; Q : out STD_LOGIC); end Lab4b;
Write a program to implement BFS/ DFS routine in a connected graph
what is the extension of SPDS Dynamic cluster tables?