Header Ads Widget

C program to find the minimum between two numbers

 C program to find the minimum between two numbers

Given two numbers , write a program to find the minimum between both .

Sample input

5 
4

Sample output

4 is minimum

C program to find the minimum between two numbers

The objective of code is to find the minimum between two numbers given by user .

Code(C):-

#include<stdio.h>
int main()
{
int a,b;
scanf("%d%d",&a,&b);
if(a<b)
printf("%d is minimum",a);
else
printf("%d is minimum",b);
}

Output:-

5
4
4 is minimum


Recommended Post :-

HCL Coding Questions:-

Capgemini Coding Questions:-

Companies interview:-

Full C course:-    

Key points:-

Cracking the coding interview:-

 Array and string:-

Tree and graph:-

Hackerearth Problems:-

Hackerrank Problems:-

Data structure:-

 MCQs:-

Post a Comment

0 Comments