0 votes
119 views
in C program by (1.7k points)
edited

 Create a simple code fragment that will swap the values of two variables num1 and num2.

1 Answer

0 votes
by (1.7k points)
selected by
 
Best answer
int temp;

temp = num1;

num1 = num2;

num2 = temp;

 

Related questions

0 votes
1 answer 126 views
0 votes
1 answer 186 views
0 votes
1 answer 112 views
asked Jun 11, 2022 in Python by Doubtly (98.9k points)
0 votes
1 answer 231 views

Doubtly is an online community for engineering students, offering:

  • Free viva questions PDFs
  • Previous year question papers (PYQs)
  • Academic doubt solutions
  • Expert-guided solutions

Get the pro version for free by logging in!

5.7k questions

5.1k answers

108 comments

557 users

...