1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
son4ous [18]
3 years ago
8

Write a program in c++ to read two integers, calculate and print the smallest

Computers and Technology
1 answer:
Shalnov [3]3 years ago
3 0

Answer:

#include<iostream>

using namespace std;

int main (){

int n1, n2;

cout<<"Enter 1st number";

cin>>n1;

cout<<"Enter 2nd number";

cin>>n2;

if(n1<n2){

cout<<"The 1st number is the smallest"<<endl<<" is= "<<n1;

}

else{

cout<<"The 2nd number is the smallest"<<endl<<" is= "<<n2;

}

}

return 0;

You might be interested in
Special keys that allow you to use the computer to perform specific functions
Pavel [41]

Answer:

Examples are Ctrl, Alt, Fn, Alt Gr, Shift, Caps Lock, Tab, Scroll Lock, Num lock, Esc, Windows Key, Backspace, Enter...

8 0
3 years ago
Which storage con be used<br>as permanent storage<br>a) Rom<br>6) RAM, © main memery​
Veseljchak [2.6K]

Answer:

ROM

Explanation:

Data in ROM does not erase itself when the computer is shut down. The data is permentely written and stored.

4 0
3 years ago
Which field uses computer programs to automate tasks so that they can be performed better than by humans ?
rewona [7]

Answer:

ran out of comments

Explanation:  :)

5 0
2 years ago
Write the statement that includes a friend function named before in the class dateType that takes as parameters two objects of t
Lerok [7]

Answer:

In opp friend function is a function that gives the same access to private and protected data. It is declared in class that is granting access.

Explanation:

#include<iostream.h>

using namespace std;

class Sum

{

 int a, b, add;

 public:

 void input()  

{

 cout << "Enter the value of l and m:";

 cin >> l>>m;     taking input from users

}

 friend void add(sum &t);

 void display()  

{

  cout << "The sum is :" << z;

}

};

 void add(sum & p)  

{

  p.add = p.a + p.b;

}

 int main()  

{

  sum p1;

  p1.input();

  add(p1);

  p1.display();

  return false;  

if(display==5)  

{

 return true;  //true is returned if sum is equal to 5

}

else        //if they are not the same

{

 return false;

}

}

8 0
3 years ago
List the final state of the cache, with each valid entry represented as a record of &lt; index, tag, data &gt;.
yanalaym [24]
There is not enough information to give correct answer. Anyway, I guess, I've seen this question before and I know the answer. I wrote it in binary. So if your task's details look like this: tag bits 31-10 2; index bits 9-4; offset bits 3:0; your answer is:

<000000, 0001, mem[1024]>
<000001, 0011, mem[3088]>
<001011, 0000, mem[176]>
<001000, 0010, mem[2176]>
<001110, 0000, mem[224]>
<001010, 0000, mem[160]> 
8 0
3 years ago
Other questions:
  • Who is the CEO of Quora?
    15·1 answer
  • Missy creates a personal budget. She enters her current savings account balance in cell D3. In cell A3, she calculates her incom
    13·2 answers
  • If a fire should break out in your building, which of the following actions is NOT recommended?
    9·2 answers
  • Write a program that asks for the weight of a package and the distance it is to be shipped. This information should be passed to
    12·1 answer
  • ) A popular PivotChart that is used in Access is (Points : 4) column.
    9·1 answer
  • What kind of software consists of programs designed to make users more productive and/or assist them with personal tasks?
    10·1 answer
  • Countries need to engage in trade of natural resources because of distribution in the earth. For instance, countries such as Sau
    9·1 answer
  • Why won't Brainly let me send a link? This is just du*mb! I want to send good articles explaining a content, and this site just
    5·1 answer
  • 1. Select the Volatile Memory *
    8·1 answer
  • Edhesive 2.3 code practice question 1​
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!