Answer Posted / balaji
/*this program is used to add two numbers using functions */
#include<stdio.h>
#include<conio.h>
void add(int,int);
void main()
{
int x,y;
printf("enter the two digits/numbers which you want to add");
scanf("%d%d",&x,&y);
add(x,y);
getch();
}
void add(int a,int b)
{
int c;
c=a+b;
printf("the sum of %d and %d is %d",a,b,c);
}
Is This Answer Correct ? | 5 Yes | 3 No |
Post New Answer View All Answers
what is bit rate & baud rate? plz give wave forms
What is 2 d array in c?
Synonymous with pointer array a) character array b) ragged array c) multiple array d) none
What is a const pointer in c?
Explain the use of 'auto' keyword in c programming?
When should a type cast not be used?
How can you restore a redirected standard stream?
What is a structure in c language. how to initialise a structure in c?
What are structures and unions? State differencves between them.
Write a program to print fibonacci series using recursion?
What are the different types of endless loops?
Explain what is the benefit of using an enum rather than a #define constant?
Define C in your own Language.
Devise a program that inputs a 3 digit number n and finds out whether the number is prime or not. Find out its factors.
is it possible to create your own header files?