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
pogonyaev
3 years ago
10

Write a method that takes a Regular Polygon as a parameter, sets its number of sides to a random integer between 10 and 20 inclu

sive, and sets its side length to a random decimal number greater than or equal to 5 and less than 12. Use Math.random() to generate random numbers. This method must be called randomize() and it must take a Regular Polygon perimeter.
Computers and Technology
1 answer:
Fantom [35]3 years ago
8 0

Answer:

Answered below

Explanation:

//Program is written in Java programming language

Class RegularPolygon{

int sides = 0;

int length = 0;

}

public void randomize(RegularPolygon polygon){

int randomSides = (int) 10 + (Math.random() * 20);

double randomLength = 5 + (Math.random() * 11);

polygon.sides = randomSides;

polygon.length = randomLength;

}

You might be interested in
Whats a hybrid wired network
LuckyWell [14K]
A hybrid network is any computer network that uses more than one type of connecting technology or topology. For example, a home network that uses both Wi-Fi and Ethernet cables to connect computers is a hybrid.
5 0
3 years ago
The equation of certain traveling waves is y(x.t) = 0.0450 sin(25.12x - 37.68t-0.523) where x and y are in
NNADVOKAT [17]

Answer:

A. 0.0450

B. 4

C. 0.25

D. 37.68

E. 6Hz

F. -0.523

G. 1.5m/s

H. vy = ∂y/∂t = 0.045(-37.68) cos (25.12x - 37.68t - 0.523)

I. -1.67m/s.

Explanation:

Given the equation:

y(x,t) = 0.0450 sin(25.12x - 37.68t-0.523)

Standard wave equation:

y(x, t)=Asin(kx−ωt+ϕ)

a.) Amplitude = 0.0450

b.) Wave number = 1/ λ

λ=2π/k

From the equation k = 25.12

Wavelength(λ ) = 2π/25.12 = 0.25

Wave number (1/0.25) = 4

c.) Wavelength(λ ) = 2π/25.12 = 0.25

d.) Angular frequency(ω)

ωt = 37.68t

ω = 37.68

E.) Frequency (f)

ω = 2πf

f = ω/2π

f = 37.68/6.28

f = 6Hz

f.) Phase angle(ϕ) = -0.523

g.) Wave propagation speed :

ω/k=37.68/25.12=1.5m/s

h.) vy = ∂y/∂t = 0.045(-37.68) cos (25.12x - 37.68t - 0.523)

(i) vy(3.5m, 21s) = 0.045(-37.68) cos (25.12*3.5-37.68*21-0.523) = -1.67m/s.

5 0
3 years ago
When we focus on stereotypes we may ___________________. a. experience culture shock b. develop ethnocentrism c. unconciously lo
alisha [4.7K]
When we focus on stereotypes we may <span>unconsciously look for information to support our generalizations .</span>
3 0
2 years ago
Read 2 more answers
Describing Work Styles for Farmworkers and Laborers, Crop
Olegator [25]

Answer:

it is A,B,E,F,G

Explanation:

can i have brainliest please.

7 0
3 years ago
Read 2 more answers
A customer comes into a grocery store and buys 8 items. Write a PYTHON program that prompts the user for the name of the item AN
Dmitrij [34]

Answer:

name = []

price = []

for i in range(0,8):

item_name = input('name of item')

item_price = input('price of item')

name.append(item_name)

price.append(item_price)

for i in range(0, 8):

print(name[i], '_____', price[i])

Explanation:

Python code

Using the snippet Given :

Apples 2.10

Hamburger 3.25

Milk 3.49

Sugar 1.99

Bread 1.76

Deli Turkey 7.99

Pickles 3.42

Butter 2.79

name = []

price = []

#name and price are two empty lists

for i in range(0,8):

#Allows users to enter 8 different item and price choices

item_name = input('name of item')

item_price = input('price of item')

#user inputs the various item names and prices

#appends each input to the empty list

name.append(item_name)

price.append(item_price)

for i in range(0, 8):

print(name[i], '_____', price[i])

# this prints the name and prices of each item from the list.

3 0
2 years ago
Other questions:
  • A ____ database supports data distributed across several different sites.
    7·1 answer
  • What are the main types of computer software?
    5·2 answers
  • ___________is a security strategy that applies multiple layers of defense because there is an assumption that any single protect
    12·1 answer
  • Controlled intersections use some form of which of the following:
    7·1 answer
  • 110101111.11011 to decimal (base 10)
    6·1 answer
  • What may happen if there is too much harmony in a design?
    14·1 answer
  • DJ Davon is making a playlist for an internet radio show; he is trying to decide what 1212 songs to play and in what order they
    12·1 answer
  • A _____ are devices that permit a user to connect to a digital t-carrier service.
    6·1 answer
  • Which are the top 10 Popular Cars and Video Games get max ammount of point that we can give​
    12·2 answers
  • In _________, the process requests permission to access and modify variables shared with others. a) entry section b) critical se
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!