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
Nadusha1986 [10]
2 years ago
15

Q6. Ask for two numbers. If the first one is larger than the second, display the second number first and then the first number,

otherwise show the first number first and then the second.
Engineering
1 answer:
Shalnov [3]2 years ago
6 0

Answer:

Number1 = input("Choose a number: )

Number2 = input("Choose a second number: )

if number1 > number2:

print(number2\nnumber1)

else:

print(number1\nnumber2)

Explanation:

I'm assuming that you want it in python.

You might be interested in
Java Programming: Loops and Conditionals
velikii [3]

Answer:

  1. import java.util.Scanner;
  2. import java.util.Random;
  3. public class Main {
  4.    public static void main(String[] args) {
  5.        Scanner input = new Scanner(System.in);
  6.        Random rand = new Random();
  7.        System.out.print("Enter number of questions you wish to practice: ");
  8.        int n = input.nextInt();
  9.        int i = 1;
  10.        while(i <= n){
  11.            int num1 = 1 + rand.nextInt(10);
  12.            int num2 = 1 + rand.nextInt(10);
  13.            int answer = num1 * num2;
  14.            System.out.print("Question " + i + ": " + num1 + " x " + num2 + " = ");
  15.            int response = input.nextInt();
  16.            if(response == answer){
  17.                System.out.println("Correct answer!");
  18.            }
  19.            else{
  20.                System.out.println("Wrong answer. It should be " + answer);
  21.            }
  22.            i++;
  23.        }
  24.    }
  25. }

Explanation:

Firstly, we import Scanner and Random classes (Line 1-2) as we need to get user input for number of questions and generate random number in each question.

Next, create a Scanner and Random object (Line 7-8).  Prompt user to input number of question and get the input using the Scanner object (Line 10-11).

Next create a while loop and set the condition to loop for n number of times (based on number of questions) (Line 14). In the loop, use Random object nextInt method to generate two integers between 1 -10 (Line 15-16). Prompt user to input an answer using the Scanner object (Line 18-19). If the response is matched with answer print a correct message (Line 21-22) other wise inform user they write a wrong answer and show the correct answer (Line 24-25).

8 0
4 years ago
How does sea navigation work?
ahrayia [7]

Answer:

a clock

Explanation:

you use a clock in water

3 0
3 years ago
A car engine with a thermal efficiency of 33% drives the air-conditioner unit (a refrigerator) besides powering the car and othe
fgiga [73]

Answer:

The rate of fuel required to drive the air conditioner Q_h = 6.061 kW

The flow rate of the cold air is  \r m = 0.30765 kg/s

Explanation:

From this question we are told that

    The efficiency is \eta = 33% = 0.33

   Temperature for the hot day is  T_h = 35^oC = 308 K \  \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ (35+273)

        Temperature after cooling is  T_c = 5^oC = 278K

      The input power is  P_{in} = 2kW

The rate of fuel required to drive the air conditioner can be mathematically represented as

              Q_h = \frac{P_{in}}{\eta}

                    = \frac{2}{0.33} = 6.061 kW

From the question the air condition is assumed to be half as a Carnot refrigeration unit

 This can be Mathematically interpreted in terms of COP(coefficient of performance) as

             \beta_{air} = 0.5 \beta

where \beta  denotes COP and is mathematically represented as

                     \beta = \frac{Q_c}{P_{in}}

= >              Q_c = \beta P_{in}

Where Q_c is the rate of flue being burned for cold air to flow

Now if  the COP of a Carnot refrigerator is having this value

                \beta_{Carnot } = \frac{T_c}{T_h - T_c}

                            = \frac{278}{308-278}

                            \beta_{Carnot} = 9.267\\

Then

     \beta_{air} = 0.5 * 9.2667

            = 4.6333

Now substituting the value of \beta to solve for Q_c

                             Q_c = \beta P_{in}

                                  = 4.6333 *2

                                  9.2667kW

The equation for the rate of fuel being burned for the cold air to flow

                       Q_c = \r mc_p \Delta T

Making the flow rate of the cold air

                       \r m = \frac{Q_c}{c_p \Delta T}

                            = \frac{9.2667}{1.004}* (308 - 278)

                            = 0.30765 kg/s

                         

                             

4 0
3 years ago
Construct a Mohr circle for the stress element at A in problem 2. Using ruler and compass, draw the Mohr circle to the scale. Dr
serious [3.7K]

Answer:

hello your question is incomplete attached below is the missing diagram to the question and the detailed solution

Answer : principal stresses : 0.82 MPa, -33.492 MPa

              shear stress = 17.157 MPa

              ∅ = 9.09 ≈ 10°

Explanation:

The principal stress ( б1 ) = 0.82 MPa

                                 ( б2 ) = -33.492 MPa

The shear stress = 17.157 MPa

∅ = 9.09 ≈ 10°

attached below is the detailed solution and the Mohr's circle

7 0
3 years ago
Which of the following is lost when the computer is turned off? ILL MARK BRAINLEST
Pavel [41]

Answer:

cloud storage is the answer

6 0
3 years ago
Read 2 more answers
Other questions:
  • One-dimensional, steady-state conduction with uniform internal energy generation occurs in a plane wall with a thickness of 50 m
    14·1 answer
  • A cylinder contains 480 cm3 of loose dry sand which weighs 820 g. Under a static load of 200 kPa the volume is reduced 1%, and t
    15·1 answer
  • 2.13 LAB: Expression for calories burned during workout
    5·1 answer
  • The part dimension for an injection-molded part made of polycarbonate is specified as 4.00 in. Compute the corresponding dimensi
    15·1 answer
  • Steven is starting a project that requires a specialized, experienced contractor. Which selection process is the most suitable f
    11·1 answer
  • A large plate is fabricated from a steel alloy that has a plane strain fracture toughness of 50.0 MPa-m1/2 . If, during service
    10·1 answer
  • 1. What's an object in your everyday life that has a lot of Kinetic Energy? How do you know it has a lot?
    5·1 answer
  • What is the most common type of suspensions system used on body over frame vehicles?
    15·1 answer
  • David wants to obtain a job as a quality engineer at a manufacturing facility. Which of the following paths should he follow to
    15·1 answer
  • Primary productivity is not limited by _______. a. the availability of sunlight b. time c. the availability of nutrients d. acce
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!