c++ program to find smallest number between 2

c++ program to find minimum number between 2

Program:-

Method 1
c++ program to find smallest number between 2 using if-else statement



Method 2
c++ program to find smallest number between 2 using conditional operator


Output:-

Enter 1st number
21
Enter 2nd number
29
21 is smallest number

Output:-

Enter 1st number
59
Enter 2nd number
18
18 is smallest number

One Comment

  1. can i know how the smallest of two numbers can be found using = operator overloading

    ReplyDelete

Add your comments here

Back to Top