Sum Of Two Numbers In C - Learn Engineering

All the news and updates relevant to Engineering. You can also Write a post here

Breaking

Saturday, May 16, 2020

Sum Of Two Numbers In C



Today we are going to learn about the Addition of Two Numbers(Integer Value) Using C-Programming.

Testcase Input: 5 10                                                   Expected-Output: 15

#include<stdio.h>
int main ( )
{
    int num1, num2, sum=0 ;
    scanf("%d %d" , &num1 , &num2) ;
    sum = num1 + num2 ;
    printf ( "%d" , sum );
    return 0;
}

Result: 

15

Comment Your Queries,

1 comment: