How to calculate sum
Answers were Sorted based on User's Feedback
Answer / deepanshu dubey
#include<stdio.h>
#include<conio.h>
#include<math.h>
main()
{
int a,b,c;
printf("Enter two numbers\n");
scanf("%d%d",&a,&b);
c=a+b;
printf("%d\n",c);
}
Is This Answer Correct ? | 8 Yes | 2 No |
Answer / avinash jadhav
#include<stdio.h>
#include<conio.h>
#include<math.h>
void main()
{
int num1,num2,sum;
clrscr();
printf("\nEnter the 2 numbers\n");
scanf("%d%d",&a,&b);
sum=num1+num2;
printf("The sum of the two number is %d\n",sum);
getch();
}
Is This Answer Correct ? | 1 Yes | 0 No |
write a program to display & create a rational number
What is structure data type in c?
Can I use base-2 constants (something like 0b101010)? Is there a printf format for binary?
How can I do peek and poke in c?
What is a string?
What is variable and explain rules to declare variable in c?
Is main is user defined function?
What do you mean by command line argument?
What is the best way to store flag values in a program?
What is the right way to use errno?
What is a method in c?
What's the best way to declare and define global variables?