Showing posts with label Basic I/O and Data Types. Show all posts
Showing posts with label Basic I/O and Data Types. Show all posts

Wednesday, 11 March 2015

Program3: Basic I/O and Data Types

Program3:

#include<stdio.h>
#include<conio.h>
void main( )
{
int a,b;
printf("Enter a and b Values: ");
scanf("%d%d",&a,&b);
printf("Addition of a and b is %d\n",a+b);
printf("Substraction of a and b is %d\n",a-b);
printf("Multiplication of a and b is %d\n",a*b);
printf("Division of a and b is %d\n",a/b);
printf("Modulus of a and b is %d\n",a%b);
}


Output:


Program1: Basic I/O and Data Types

Program:

#include<stdio.h>
#include<conio.h>
int main( )
{
               clrscr( ); //Clear the Screen Contents
               printf("Welcome\n");
               printf("To\n");
               printf("Let Us Code in C\n");
}


Execution Process in Borland C

Compiling: ALT + F9
Linking:      F9
Execution:   CLT + F9

Output: