Logo 
Search:

C Programming Articles

Submit Article
Home » Articles » C Programming » Homework HelpRSS Feeds

Program to add 2 numbers

Posted By: Lionel Thomas     Category: C Programming     Views: 3581

Write a program to add 2 numbers

Code for Program to add 2 numbers in C Programming

#include<stdio.h>
#include<conio.h>
main()
{
    int number;
    float amount;
    clrscr();

    number = 100;
    amount = 30.75 + 75.35;
    printf("%d\n", number);
    printf("%5.2f", amount);

    getch ();
    return 0;
}
  
Share: 


Didn't find what you were looking for? Find more on Program to add 2 numbers Or get search suggestion and latest updates.

Lionel Thomas
Lionel Thomas author of Program to add 2 numbers is from New York, United States.
 
View All Articles

 
Please enter your Comment

  • Comment should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].

 
No Comment Found, Be the First to post comment!