This blog consists of C and C++ programs. C and C++ programming is the basics to learn any programming language. Most of the programs are provided with their respective outputs. This blog also contains Data Structures programs using Object-Oriented Programming (C++). Some of the best books for learning C and C++ programming are also mentioned.

Friday 1 November 2013

C program for Arithmetic Operators

C Program for Arithmetic Operators:

#include<stdio.h>
#include<conio.h>
main()
{
int a,b;
clrscr();
printf("Enter the value of a:");
scanf("%d", &a);
printf("\nEnter the value of b:");
scanf("%d", &b);
printf("\nThe Addition value is = %d", a+b);
printf("\nThe Subtraction value is = %d", a-b);
printf("\nThe Multiplication value is = %d", a*b);
printf("\nThe Division value is = %d", a/b);
printf("\nThe Modulus value is = %d", a%b);
getch();
}

No comments:

Post a Comment