Home
About
Contact
Header Ads Widget
Home
Coding Questions
_C/C++ Programs
_Python Programs
_Data Structure Programs
_Competitive Coding
Practice Problems
Key Points
Notes
MCQs
Interview
Home
c-programs
Program to swap to numbers without using third variable in c language
Program to swap to numbers without using third variable in c language
Rajnish Tripathi
08:02
program:-
#include<
stdio.h
>
#include<
conio.h
>
void
main
()
{
int
a
,
b
;
printf
(
"Enter two numbers"
);
scanf
(
"%d%d"
,&
a
,&
b
);
a
=
a
+
b
;
b
=
a
-
b
;
a
=
a
-
b
;
printf
(
"first number=%d and second number=%d"
,
a
,
b
);
getch
();
}
Post a Comment
4 Comments
Unknown
20:05
nice work
Reply
Delete
Replies
Reply
anupam tripathi
15:02
Thank you
Reply
Delete
Replies
Reply
anupam tripathi
15:03
Keep it
Reply
Delete
Replies
Reply
Sadab Hussain
16:35
Bahoot sandar
Reply
Delete
Replies
Reply
Add comment
Load more...
Popular post
PPS 1st year (C programming ) handwritten notes Aktu
11:47
COA notes of all the units aktu university
14:10
pps unit 1 notes
09:54
Social Plugin
MCQs
3/MCQs/post-list
Tags
c-programs
Companies
competitve programs
Data structure
doubts
key points
MCQs
Notes
practice problems
python
4 Comments
nice work
ReplyDeleteThank you
ReplyDeleteKeep it
ReplyDeleteBahoot sandar
ReplyDelete