Visitor counter white motion bluer

Sunday, October 21, 2012

We can execute Addition,Subtraction,Multiplication and Division operation using Turbo C programmes. We can Add, Subtract, Multiply and Divide  numbers in two different ways -  choose numbers from keyboard or assign values with variables.

Here is a simple programme  for adding two numbers assign values with variables.

INPUT

#include<stdio.h>                    /*  Using library function  */
#include<conio.h>                 /*  Using library function to support printf( ) function  */


void main()                            /*  Using void main( )  function  */


 {
        clrscr();                                  /*  To clear the screen  */
        int a, b, c;                               /*  Using integer type values  */
        a=10;                                     /*  Assign the value 10 with variable a */
        b=5;                                       /*  Assign the value 5 with variable b */
        c=a+b;                                  /*  Generate Addition operation  */
        printf("The Summation of the numbers is:",c);                           /*  To print the text  */
        getch();                                                                                    /*  To show output on the screen  */
        return 0;                                                                                   /*Return null value */
 }


OUTPUT

The Summation of the numbers is: 15

Turbo C Tutorial For Beginner

 Using Borland Turbo C Software we can compile, run and print any programmes. In turbo C programme there are several parts - library function which is called header, void main() function and body of the programme containing different functions, methods and variables.

Here is the example of a simple programme to print text......

INPUT 


#include<stdio.h>                                               /*  using library function  */
#include<conio.h>                                           /*  using library function to support printf( ) function  */

void main()                                                        /*  using void main( )  function  */

{                                                              
          clrscr();                                                          /*  to clear the screen  */
          printf("HELLO   AMANDA!!!!");             /*  To print the text  */
          getch();                                                          /*  To show output on the screen  */
}



OUTPUT

HELLO   AMANDA!!!!