answer.
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
Ira Lisetskai [31]
2 years ago
4

Your friend plays a game of chance based on the sum of the rolls of three six-sided dice. Clearly the totals can range between t

hree (all ones) and eighteen (all sixes), however, your friend decides he wants to know the probability of each value appearing. Rather than do the mathematics he decides to find out by trials. He rolls the dice 1,000 times and counts the number of threes that occur. Then he rolls the dice another 1,000 times and counts the fours and so forth. You decide you’d rather him play Frisbee Golf with you and so you decide to model his process using a program. Writing and running the program will be faster than his method of finding the probabilities. Your program should output the count of each number in sequence, just as he would do.
Engineering
1 answer:
Alisiya [41]2 years ago
3 0

Answer:

import java.util.*;

class ProbabilityOfRollingThreeDice

{

   public static void main(String[] args)

   {

      Random rnd = new Random();

      System.out.print("Enter a random seed: ");

      long seed = new Scanner(System.in).nextLong();

      rnd.setSeed(seed);

      for(int i = 3; i <= 18; i++)

      {

         int count = 0;

         

         for(int j = 0; j < 1000; j++)

         {

            int roll1 = rnd.nextInt(6) + 1;

            int roll2 = rnd.nextInt(6) + 1;

            int roll3 = rnd.nextInt(6) + 1;

            int sum = roll1 + roll2 + roll3;

            if(sum == i)

                 count++;

         }      

         System.out.println("The value " + i + " occurred " + count + " times.");

      }

   }

}

You might be interested in
Your roommate wants to learn about organizational chart. You can tell her that these charts can tell you all of these about an o
mars1129 [50]

Answer:

Control mechanisms

Explanation:

Organizational chart of any company will give details of different aspects of the company such as the major sub-units of the organization with the names of team leaders for different sub-units, it can also give you the span of control and the division of work within the company. However, the chart can't show you control mechanisms of different departments.

4 0
2 years ago
A fuel oil is burned with air in a furnace. The combustion produces 813 kW of thermal energy, of which 65% is transferred as hea
DENIUS [597]

Answer:

im not sure

Explanation:

8 0
2 years ago
A single crystal of a metal that has the FCC crystal structure is oriented such that a tensile stress is applied parallel to the
morpeh [17]

The magnitude of applied stress in the direction of 101 is 12.25 MPA and in the direction of 011, it is not defined.                                          

<u>Explanation</u>:        

<u>Given</u>:

tensile stress is applied parallel to the [100] direction

Shear stress is 0.5 MPA.

<u>To calculate</u>:

The magnitude of applied stress in the direction of [101] and [011].

<u>Formula</u>:

zcr=σ cosФ cosλ

<u>Solution</u>:

For in the direction of 101

cosλ = (1)(1)+(0)(0)+(0)(1)/√(1)(2)

cos λ = 1/√2

The magnitude of stress in the direction of 101 is 12.25 MPA

In the direction of 011

We have an angle between 100 and 011

cosλ = (1)(0)+(0)(-1)+(0)(1)/√(1)(2)

cosλ  = 0

Therefore the magnitude of stress to cause a slip in the direction of 011 is not defined.                                                                                                                                                                      

                                                                                   

                                                                                                                                                   

                                                                                                                                                             

5 0
2 years ago
A double-acting duplex pump with 6.5-in. liners, 2.5-in. rods, and 18-in. strokes was operated at 3,000 psig and 20 cycles/min.
Stella [2.4K]

Answer:

Pump factor = Fp =  7.854 gal/cycle

Ev = 82.00 %

P_H = 183.29 hp

Explanation:

Given data:

Dimension of duplex pump

6.5 inch liner  

2.5 inch rod

18 inch strokes

Pressure 3000 psig

Pit dimension

7 ft wide

20 ft long

Ls = 18 inch

Velocity = (18)/10

volumetric efficiency is given as E_v = (Actual flow rate)/(Theortical flow rate) * 100

we know that flow rate is given as = Area * velocity

Theoritical flow rate = \frac{\pi}{2}\times Ls(2d_l^2 - d_r^2)\times N

Ev = \frac{7\times 12 \times 20\times 12\times 12 \times \frac{18}{10} inch^3/min}{\frac{\pi}{2} \times 18 (2\times 6.5^2 -2.5^2) \times 20}

Ev = 82.00 %

Pump factor Fp = = \frac{\pi}{2}\times Ls(2d_l^2 - d_r^2)\times Ev

Fp =\frac{\pi}{2} \times 18 (2\times 6.5^2 -2.5^2) \times 0.82

Fp = 1814.22 in^3/cyl

Fp =  7.854 gal/cycle

Flow rate q = NFp = 20 \times 7.854 = 157.08 gal/min

Power Ph = \frac{\DeltaP q}{1714} = \frac{3000 \times 157.08}{1714} = 274.93 hp

6 0
2 years ago
. A cylindrical metal specimen having an original diameter of 12.8 mm (0.505 in.) and gauge length of 50.80 mm (2.000 in.) is pu
kogti [31]

Answer:

% reduction in area==PR=0.734=73.4%

% elongation=EL=0.42=42%

Explanation:

given do=12.8 mm

df=6.60

Lf=72.4 mm

Lo=50.8 mm

% reduction in area=((\pi*(do/2)^2)-(\pi*(df/2)^2)))/\pi*(do/2)^2

substitute values

% reduction in area=73.4%

% elongation=EL=((Lf-Lo)/Lo))*100

% elongation=((72.4-50. 8)/50.8)*100=42%

6 0
2 years ago
Other questions:
  • You are working in a lab where RC circuits are used to delay the initiation of a process. One particular experiment involves an
    13·1 answer
  • The hot water needs of an office are met by heating tab water by a heat pump from 16 C to 50 C at an average rate of 0.2 kg/min.
    5·1 answer
  • Determine F12 and F21 for the following configurations: (a) A long semicircular duct with diameter of 0.1 meters: (b) A hemisphe
    10·1 answer
  • Can crushers help us recycle in a space efficient way which is good for saving the earth and for giving you more room in your ap
    7·1 answer
  • Technician A says that the most efficient method of EVAP system leak detection is introducing smoke under low pressure from a ma
    7·1 answer
  • The following passage contains a fragment. Select the correct revision. Presley took the exuberance of gospel and added the freq
    7·1 answer
  • The atomic radii of a divalent cation and a monovalent anion are 0.77 nm and 0.136 nm, respectively.1- Calculate the force of at
    11·1 answer
  • ) A given system has four sensors that can produce an output of 0 or 1. The system operates properly when exactly one of the sen
    9·1 answer
  • A commercial refrigerator with refrigerant-134a as the working fluid is used to keep the refrigerated space at -30C by rejecting
    13·1 answer
  • What term describes a guardrail system
    13·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!