write a program that takes two numbers from user that
prints the smallest number
Answers were Sorted based on User's Feedback
Answer / hemant jakkani
#include <stdio.h>
#include <string.h>
main()
{
int x,y;
scanf("%d%d",&x,&y);
if(x>y)
printf("First Number is greater: %d",x);
else
printf("Second Number is greater:%d",y);
}
| Is This Answer Correct ? | 6 Yes | 1 No |
Answer / vaishnavi
#include<iostream.h>
void main()
{
int a,b;
cout<<"Enter two numbers";
cin>>a>>b;
if(a>b)
cout<<a<<"is greater";
else
cout<<b<<is greater";
}
| Is This Answer Correct ? | 2 Yes | 1 No |
What is the difference between public and private data members?
Explain Memory Allocation in C/C++ ?
What does flush do c++?
What are the types of container classes?
Write any small program that will compile in "C" but not in "C++"
Explain data encapsulation?
What is the difference between shallow copy and deep copy?
What is a c++ class?
What are friend functions?
When a function is made inline. Write the situation where inline functions may not work.
How does list r; differs from list r();?
What is size of Empty Class?