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
Svetllana [295]
3 years ago
12

Explain the four criteria for proving the correctness of a logical pretest loop construct of the form "while B do S end". And pr

ove the correctness of the following:
while B do S end
Engineering
1 answer:
evablogger [386]3 years ago
6 0

Answer:

Check the explanation

Explanation:

The loop invariant has to satisfy some amount of requirements to be of good use. Another complex factor as to why a loop is the question of loop termination. A loop that doesn’t terminate can’t invariably be correct, and in fact the computation in whatever form amounts to nothing. The total axiomatic description of a while construct will have to involve all of the following to be true, in which I is the loop invariant:

P => I

{I and B} S {I}

(I and (not B)) => Q

Then the loop terminates

You might be interested in
If a motorist moves with a speed of 30 km/hr, and covers the distance from place A to place B
Sergio039 [100]

Answer:

105 km

Explanation:

The motorist was going 30 km/hr, and it took 3 hours 30 minutes. That's 3.5 hours. 3.5×30=105

5 0
3 years ago
Which of the following ranges depicts the 2% tolerance range to the full 9 digits provided?
Lyrx [107]

Answer:

the only one that meets the requirements is option C .

Explanation:

The tolerance of a quantity is the maximum limit of variation allowed for that quantity.

To find it we must have the value of the magnitude, its closest value is the average value, this value can be given or if it is not known it is calculated with the formula

         x_average = ∑ x_{i} / n

The tolerance or error is the current value over the mean value per 100

         Δx₁ = x₁ / x_average

         tolerance = | 100 -Δx₁  100 |

bars indicate absolute value

let's look for these values ​​for each case

a)

    x_average = (2.1700000+ 2.258571429) / 2

    x_average = 2.2142857145

fluctuation for x₁

        Δx₁ = 2.17000 / 2.2142857145

        Tolerance = 100 - 97.999999991

        Tolerance = 2.000000001%

fluctuation x₂

        Δx₂ = 2.258571429 / 2.2142857145

        Δx2 = 1.02

        tolerance = 100 - 102.000000009

        tolerance 2.000000001%

b)

    x_average = (2.2 + 2.29) / 2

    x_average = 2,245

fluctuation x₁

         Δx₁ = 2.2 / 2.245

         Δx₁ = 0.9799554

         tolerance = 100 - 97,999

         Tolerance = 2.00446%

fluctuation x₂

          Δx₂ = 2.29 / 2.245

          Δx₂ = 1.0200445

          Tolerance = 2.00445%

c)

   x_average = (2.211445 +2.3) / 2

   x_average = 2.2557225

       Δx₁ = 2.211445 / 2.2557225 = 0.9803710

       tolerance = 100 - 98.0371

       tolerance = 1.96%

       Δx₂ = 2.3 / 2.2557225 = 1.024624

       tolerance = 100 -101.962896

       tolerance = 1.96%

d)

   x_average = (2.20144927 + 2.29130435) / 2

   x_average = 2.24637681

       Δx₁ = 2.20144927 / 2.24637681 = 0.98000043

       tolerance = 100 - 98.000043

       tolerance = 2.000002%

       Δx₂ = 2.29130435 / 2.24637681 = 1.0200000017

       tolerance = 2.0000002%

e)

   x_average = (2 +2,3) / 2

   x_average = 2.15

   Δx₁ = 2 / 2.15 = 0.93023

   tolerance = 100 -93.023

   tolerance = 6.98%

   Δx₂ = 2.3 / 2.15 = 1.0698

   tolerance = 6.97%

Let's analyze these results, the result E is clearly not in the requested tolerance range, the other values ​​may be within the desired tolerance range depending on the required precision, for the high precision of this exercise the only one that meets the requirements is option C .

4 0
3 years ago
Consider a space shuttle weighing 100 kN. It is travelling at 310 m/s for 30 minutes. At the same time, it descends 2200 m. Cons
mixas84 [53]

Answer:

work done = 48.88 × 10^{9} J

Explanation:

given data

mass = 100 kN

velocity =  310 m/s

time = 30 min = 1800 s

drag force = 12 kN

descends = 2200 m

to find out

work done by the shuttle engine

solution

we know that work done here is

work done = accelerating work - drag work - descending work

put here all value

work done = ( mass ×velocity ×time  - force ×velocity ×time  - mass ×descends )  10³ J

work done = ( 100 × 310 × 1800  - 12×310 ×1800  - 100 × 2200 )  10³ J

work done = 48.88 × 10^{9} J

6 0
3 years ago
Provide an argument justifying the following claim: The average (as defined here) of two Java ints i and j is representable as a
ahrayia [7]

Answer:

public static int average(int j, int k) {

return (int)(( (long)(i) + (long)(j) ) /2 );

}

Explanation:

The above code returns the average of two integer variables

Line 1 of the code declares a method along with 2 variables

Method declared: average of integer data type

Variables: j and k of type integer, respectively

Line 2 calculates the average of the two variables and returns the value of the average.

The first of two integers to average is j

The second of two integers to average is k

The last parameter ensures average using (j+k)/2

3 0
2 years ago
Which rigid motion maps the solid-line figure onto the dotted-line figure?
Agata [3.3K]
I would love to answer but unfortunately there is no picture.
5 0
3 years ago
Other questions:
  • Write a grammar for a language whose sentences start with an even and non-zero number of x’s, end with an odd number of z’s, and
    11·1 answer
  • A 2.599 g sample of a new organic material is combusted in a bomb calorimeter. The temperature of the calorimeter and its conten
    13·1 answer
  • Air in a 10 ft3 cylinder is initially at a pressure of 10 atm and a temperature of 330 K. The cylinder is to be emptied by openi
    10·2 answers
  • Ok I need a new laptop but I'm not sure which one. The Surface laptop 3 is better in many fields like the camera, speaker, audio
    14·1 answer
  • Technician A says that reversing the direction of refrigerant (as with a heat pump system) could be done to provide cabin heat.
    14·1 answer
  • ?Why the efficiency of Class A amplifier is very poor​
    11·1 answer
  • According to the video, what are some tasks that Construction Managers perform? Check all that apply.
    9·2 answers
  • Which of the following is an example of a pulley?
    10·2 answers
  • Drag each label to the correct location on the table. Match to identify permanent and temporary structures.
    15·1 answer
  • Analyze the example of this band saw wheel and axle. The diameter of the wheel is 14 inches. The diameter of the axle that drive
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!