Each week, the Pickering Trucking Company randomly selects one of its 30 employees to take a drug test. Write an application that determines which employee will be selected each week for the next 52 weeks. Use the Math.random() function explained in Appendix D to generate an employee number between 1 and 30; you use a statement similar to:

Answers

Answer 1

Answer:

In Java:

import java.util.Random;

public class Main{

public static void main(String args []){

  int Employee;

  for(int weeks = 1;weeks<=52;weeks++){

    Employee = 1 + (int)(Math.random() * 30);

    System.out.println("Week "+weeks+" selected employee: "+Employee);

  }

}

}

Step-by-step explanation:

This imports the Random package into the program

import java.util.Random;

public class Main{

public static void main(String args []){

Declare employee as integer (represents employee 1 to 30)

  int Employee;

Iterate from week 1 to 52

  for(int weeks = 1;weeks<=52;weeks++){

Randomly select an employee from 1 to 30 (inclusive)

    Employee = 1 + (int)(Math.random() * 30);

Print the selected employee

    System.out.println("Week "+weeks+" selected employee: "+Employee);

  }

}

}


Related Questions

please help me out
find the other endpoint of the line segment with the given endpoint (1,-9) and midpoint (-9,3)

Answers

Answer:

(-19,15)

Step-by-step explanation:

PLEASE HELP, ILL GIVE MANY POINTS AND BRAINLIEST ANSWER TOTHE FASTEST ONE

Answers

Answer:

WHATS THE QUESTION

Step-by-step explanation:

???rrtrttt r the r

At midnight in Alaska, the temperature in Sitka is 29.7 degrees Fahrenheit.
Each hour after that the temperature decreases by 1.23 degrees until the sun comes up.
What is the temperature 2 hours after midnight?

Answers

Temperature

Level : JHS

the temperature in Sitka 2 hours after midnight is :

= 29.7°F + (2 × 1.23°F)

= 29.7°F + 2.46°F

= 32.16°F

So, the temperature in Sitka 2 hours after midnight is 32.16°F

#LearnWithEXO

Answer:

27.24° F

Step-by-step explanation:

Initial temperature = 29.7° FDecrease rate = 1.23° F / h

After 2 hours the temperature is:

29.7° F - 2*1.23° F = 27.24° F

During hockey practice, Jason skates 180 yards in 20 seconds.


Based on his average speed, approximately how many yards will he skate in the next 15 seconds?whoever answers first will be marked the brainliest

Answers

The approximate yards Jason will skate in the next 15 seconds is 135 yards

Given that :

Number of yards skate in 20 seconds = 180 yards

The rate per second cannbe calculated thus :

Rate = distance / time Rate = 180 / 20 = 9 yards per second

The distance skate in 15 seconds will be:

Distance = time × rate

Distance = 15 × 9 = 135 yards

Therefore, Jason will skate 135 yards in the next 15 seconds.

Learn more :https://brainly.com/question/18904995

Please help me answer this question

Answers

Answer:

option D is right answer

i.e. _

BC

Suppose that the relation T is defined as follows.
T={(2, 2), (1, -7), (-5, 3), (3, 0)}
Give the domain and range of T.
Write your answers using set notation.

domain =

range =

Answers

The domain is all of the x values which are the first number in each set of parentheses and the range is all of the y values therefore domain = {2, 1, 5, 3} and range= {2, -7, 3, 0}

165÷11
I'm not sure sure I had got R15

Answers

Answer:

165/11= 15

Step-by-step explanation:

I used a calculator

Samantha spent 40 minutes on homework sixty percent of that time was spent on language arts how many minutes were spent in language art

Answers

Answer:

i think its b.24 minutes

Step-by-step explanation:

sorry if im wrong

Answer:

Samantha spent 24 minutes on language arts.

Step-by-step explanation:

So, 60% = 3/5.

Since Samantha spent 40 minutes in total for homework, the 40 minutes would be the denominator. Let's have the variable "x" equal how many minutes she spent on language arts. If we line up the fractions, it will be like this:

3/5 = x/40

Since we know 5 x 8 = 40, we would also multiply the numerator by 8.

3 x 8 =24.

So, Samantha spent 24/40 minutes on ELA, which is 60% of the total time.

y=-2(x+4)^2+3 find the y-intercept

Answers

Answer:

( 0, -29)

Step-by-step explanation:

Answer: ( I solve (more like the internet solve) for both x and y.

Step-by-step explanation: To find the x-intercept, substitute in  0 for y and solve for x. To find the y-intercept, substitute in 0 for x and solve for y.

PLEASE HELP ME ITS ALGEBRA THANK YOUUUU

Answers

Answer: 20

Step-by-step explanation:

so if you divide 40 w 8, it’ll be 5 which means that she reads 5 books in a month. divide 100 w 5 and you’ll get 20

your friend is trying to guess how much money you make at your job, so you give them a riddle. You tell your friend that you work 3 hours on Friday and 6 hours on Saturday, And that you also receive an allowance of $20 from your parents.. In total you are $92 every week. What would your friend have to guess your wage is in order to be correct?​

Answers

Answer:

$8 an hour

Step-by-step explanation:

1.) 92 - 20 = 72

2.) 3 x 8 = 24

3.) 6 x 8 = 48

4. 24 + 48 = 72

       

         OR

1.) 92 - 20 = 72

2.) 6 + 3 = 9

3.) 72 / 9 = 8

either way to solve gives you the correct answer as shown above. Also if answer is correct please leave ”thanks” heart

Pepe’s Pizza makes 26 pizza crusts the first week and 180 pizza crusts each subsequent week. Dianne’s Delicatessen makes 52 pizza crusts the first week and 167 pizza crusts each subsequent week. In how many weeks will the total number of pizza crusts made by Pepe’s Pizza be the same as the number of pizza crusts made by Dianne’s Delicatessen? Explain and show work to support your answer.

Answers

Answer: the total number of pizza crusts made by Pep's Pizza

equals twice the total number of pizza crusts

made by Dianne's Delicatessen when:

+52+%2B+180n+=+2%2A%28+26+%2B+90n+%29+

+52+%2B+180n+=+52+%2B+180n+

This equation is satisfied for any value of +n+,

so Pepe's always makes twice as much as Dianne's

Step-by-step explanation:

Solve this equation to determine the number of solutions 3(2 + 4) - 2 = 2(2x + 5) - 2 Plsss help its do today and I leave for school in 20 minutes I have one more question after this! ​

Answers

Answer:

duh

Step-by-step explanation:

7. (4x - 13) (2x + 37 what is x?

Answers

Answer:

8 x2 + 2x - 91

Step-by-step explanation:

56x2 + 4x -637

Please help!!!
Solve for X

Answers

Answer:

[tex]x = - \frac{1}{56} [/tex]

Step-by-step explanation:

-x/56x = 2

-1/56 = 2

x = -1/56

**The domain of f(x) = 3x + 2 is
{-1 in the range?

Answers

Answer:

Yes

Step-by-step explanation:

Graph this function on your calculator and you will see an upwards graph, if the range (y), -1 can be mapped on the graph, it is within the range.

Am i right on this one?

Answers

Answer:

yes

Step-by-step explanation:

brainliest please

Yes this is correct, i cant really explain since i already did this question on paper but I CAN tell you it is right

3. Show that x = –1 and y = 3 satisfy the linear equation 2x + 3y = 7.


4. Write three solutions for the equation 2x + 3y = 8.​

Answers

Step-by-step explanation:

2x+3y=7

solution

2-1+3+3

1+6

7 ans

What is the product of (3y^-4)(2y^-4)

6/y^6
1/6y6
6/y16
1/6y16

Answers

Answer is 1/6y16 that’s the answer

plz i need help walk me through it, thanks​

Answers

Answer:

[tex]p=36^{\circ}[/tex]

Step-by-step explanation:

We can prove that a tangent will always be perpendicular to the radius touching it. So, the other angle in the diagram is [tex]90^{\circ}[/tex].

Because all the angles of a triangle sum to [tex]180^{\circ}[/tex], we have that [tex]p+54+90=180[/tex].

We combine like terms on the left side to get [tex]p+144=180[/tex].

We subtract [tex]144[/tex] on both sides to get [tex]p=36[/tex].

So, [tex]\boxed{p=36^{\circ}}[/tex] and we're done!

$D$ is on side $\overline {AB}$ of $\triangle ABC.$ We know $\triangle ABC \sim \triangle ACD$ and $\angle A =48^\circ.$ If $BC=BD,$ what is $\angle B$ in degrees?

Answers

According to the exterior angle theorem, the exterior angle of a triangle is equal to the sum of the two opposite interior angles

The measure of ∠B is 44°

Reason:

The known parameters are;

The point D is on side [tex]\overline{AB}[/tex] of triangle ΔABC

ΔABC ~ ΔACD,

∠A = 48°

BC = CD

Required:

The measure of angle ∠B

Solution:

ΔBDC is an isosceles triangle

Let x, represent ∠B

Therefore, ∠BDC = x, by base angles of an isosceles triangle

Given that  ΔABC ~ ΔACD, and ΔBDC is an isosceles triangle, we have;

∠ADC = 2·x by exterior angle of a triangle theorem

Given ΔABC ~ ΔACD, ∠A = ∠A, and ∠ADC = 2·x, therefore, ∠ACD = x

Which gives;

48° + x + 2·x = 180° sum of angles in a triangle theorem

[tex]x = \dfrac{180^{\circ} - 48^{\circ}}{3} = 44^{\circ}[/tex]

∠B = x = 44°

The measure of ∠B = 44°

Learn more about angles in a triangle here:

https://brainly.com/question/956912

9x-5
14x+24 A

Determine the value of x.

A) x = 32.2
B) x = -5.8
C) x = -7
D) x = 7​

Answers

Answer:

letter

B. =-5.8

Step-by-step explanation:

hope its help

Which of the following graphs represents a function? Choose all that apply.

Answers

the one with the vertical parabola and the one with the straight line

detailed explanation and answer please 20 points

Answers

Step-by-step explanation:

The first part of solving the area is multiplying the rectangle. So you do 15*18 which is 270. Then to solve a triangle you make it a square/rectangle. So it would be 8*15 which is 120. Because the length is the length of the rectangle and the width is shown on top. Then because it’s a rectangle not a triangle you divide by 2 because you were adding half to it when you were making it a rectangle. So it’s 120/2 which is 60. And 270+60 is 330. So the area is 330. To get the perimeter you add all the sides together. And because one of the sides is not added but half of the bottom line is the same length as the top so it would be 18+ the 8 on the top which is 26. So 15+18+17+26 is 76. So the perimeter is 76

So the answer is the bottom one. P=76 and A=330

solve the attached question.
NO spam!
Step by step explanation needed!​

Answers

Step-by-step explanation:

hi I need help please, you can help me?

4 consecutive integers of 182

Answers

44,95,96,97

Step-by-step explanation:

first just do gcf and find your numbers with x

HELP ME PLEASE AND HURRY

the sum of a rational number and a rational number is rational.

-ALWAYS true
-SOMETIMES true
-NEVER true

Answers

thae answer is something true

Please help with the homework please thanks

Answers

I have written the answers and the steps on a piece of paper.

PLEASE HELP ITS MATH THANK YOUUUU

Answers

1millimeter = 1cm I think

Solve 2^2 + x - 4 = 0.

Answers

Answer:

x=0

Step-by-step explanation:

2^2 + x - 4 = 0

2^2 = 4

4+x-4 = 0

Combine like terms

x=0

Other Questions
Why are drugs bad for people? write the sentence as an equation. 153 added to n is the same as 143 3A ABC and point E are shown in the diagram below. Determine a possible location of point D to makeABC. CDE A car can travel at least 70 miles per hour faster than 4 times the speed of someone walking. Which inequality represents the relationship between the speed of the person walking, m, and the speed of the car, v?A. v 560mB. v 4 + 70mC. v 4m - 70D. v 4m + 70 A CD usually sells for $14.00. If the CD is 20% off, and sales tax is 7%, what is the total price of the CD, including tax? Your body makes thousands of different kinds of proteins. How many different building blocks does it use to make all these different proteins?Group of answer choices1392250 A car on a roller coaster loaded with passengers has a mass of 2.0 x 10^3 kg. At the lowest point of the the track, the radius of curvature is 24 m and the roller coaster car has a tangential speed of 17 m/s why is it important to save energy in our daily lives A star is bigger than a solar system.O TrueO False Which of the following problems weakened Europe during Medieval times? A. Black Death B. famine C. both A and B Can anyone help me with this geometry test please like I will do anything!! I will give brainlist!!Also NO links!! At the beginning of the week, the temperature was 15. During the week, it decreased by 20. What was the temperature by the end of the week? What is the percent Change of the weekly temperature? Show work 64.8=6(m+2.9) what is mplease help me and explain how did you get your answer "Wake up to reality! Nothing ever goes as planned in this world. The longer you live, the more you realize that in this reality only pain, suffering and futility exist. Where is this quote from Patrick is working on a series of photographs where, for each photo, he puts great time, detail, and care into arranging the visual elements to give the entire picture a sense of stability. What principle of design is Patrick focusing on in his photos?HarmonyProportionRhythmBalance help plsss if anyone has ap3x 3.88g of NaOH is required to neutralize a spill of hydrochloric acid. A 0.516M solution of NaOH is available for use.A. Determine the number of moles needed to complete the reaction.B. What volume of NaOH solution is needed for this reaction?C. What volume of a stock 1,15M solution would be used to make the solution used in the reaction? The length of a rectangle is 3 yards less than 5 times the width. If the perimeter is 102 yards, find the length and the width of the rectangle. Using the following data set calculate the mean 9,14,14,9,20,6,8,19,17,13,9 curious gorge es un ____ , un animal muy comico.sapo monotigrepez