I need help with this. It's while loops in python.

I Need Help With This. It's While Loops In Python.

Answers

Answer 1

Answer:

Here is a simple application running loop example in python

running = true

while(running):

# YOUR CODE HERE

Explanation:

A while loop is basically a loop of something if something is true

so if there is a boolean set to true for a application to run then use a while loop. Have a nice day! :)


Related Questions

So my teacher asked us to predict who would win in a death match, and we could choose the two characters, so Alastor from Hazbin Hotel vs Blackhat from villinous, who would win?

Answers

Answer:

I think alastor from Hazbin Hotel.

Answer:

alastor

Explanation:

i mean alastor is a demon and blackhat we dont know if he is a demon or not but i mean alastor would win he took down a flying ship that was trying to kill them

Which word best describes the feeling you have when you are in the learning zone?

A. Comfortable
B. Accomplished
C. Unsure
D. Agitated

Answers

Explanation:

This is probably something like a feedback form

but I feel unsure/comfortable

Answer: Accomplished

Explanation:

edhesive 6.8 lesson practice answers please ​

Answers

Answer: any more info yo can give me. i want to help i dont undestand

Explanation:

Answer:

import simplegui

import random

# global constants

WIDTH = 600

HEIGHT = 400

PARTICLE_RADIUS = 5

COLOR_LIST = ["Red", "Green", "Blue", "White"]

DIRECTION_LIST = [[1,0], [0, 1], [-1, 0], [0, -1]]

# definition of Particle class

class Particle:

  # initializer for particles

  def __init__(self, position, color):

      self.position = position

      self.color = color

  # method that updates position of a particle    

  def move(self, offset):

      self.position[0] += offset[0]

      self.position[1] += offset[1]

  # draw method for particles

  def draw(self, canvas):

      canvas.draw_circle(self.position, PARTICLE_RADIUS, 1, self.color, self.color)

  # string method for particles

  def __str__(self):

      return "Particle with position = " + str(self.position) + " and color = " + self.color

# draw handler

def draw(canvas):

  for p in particle_list:

      p.move(random.choice(DIRECTION_LIST))

  for p in particle_list:

      p.draw(canvas)

# create frame and register draw handler

frame = simplegui.create_frame("Particle simulator", WIDTH, HEIGHT)

frame.set_draw_handler(draw)

# create a list of particles

particle_list = []

for i in range(100):

  p = Particle([WIDTH / 2, HEIGHT / 2], random.choice(COLOR_LIST))

  particle_list.append(p)

# start frame

frame.start()

Explanation:

Megan wants to post a picture of her and her friend Jennifer on her social media page. What should Megan do before she posts the picture?

A. Add a caption.
B. Ask her friend for permission.
C. Make sure she looks good.
D. Edit the picture using Photoshop.

Answers

Answer:

B. Ask her friend for permission.

Explanation:

Answer: B ask her friend for permission

hope you do good on the test or quiz.. it would mean alot to be brainlEst

In the Business world people are often measured by their???

A- soft skills
B- hobbies
C- iq
D- technical skills

Answers

Answer: D technical skills

Which of the following numbers might this code generate: random.randint(1,9)?

0
10
11
1

Answers

Answer:

1

Explanation:

In Python programming language, the random.randint function is an abbreviation for random integers.

Basically, the random.randint is used for generating or creating a random integer numbers.

The syntax for this code can be written as;

A = random.randint(1,9)

Print ("Random number between 1 and 9 is % s" % (A))

Note, the numbers between 1 and 9 are 1, 2, 3, 4, 5, 6, 7, 8 and 9.

From the answer choices given (0, 1, 10 and 11), the only number that matches the requirement is 1.

Therefore, the number this code random.randint (1,9) might generate is 1.

NEED ASAP.


Which multimedia feature can be used to automatically move objects in your slides?
X transition
O animation
O clipart
O innovation

Answers

Animationnnnnnnnnnnnn
Animation or clip art!!

1 point
Which of the following best describes the purpose of a design
specification?
help plssss!

Answers

...You didn’t say what the choices are

HELP ASAP!!! What portfolio document is most likely to speak of your soft skills?
cover letter
transcript
recommendations
resume

Answers

Answer: resume

Explanation:

Answer:

recommendations was the right answer

Explanation:

choose the correct term to complete the sentence.

Answers

Answer:

Epoch

Explanation:

please help me
...
.... ​

Answers

Answer:

formal information searches

Explanation:

Answer:

informal information source

hope it will help if it helps please ask me in comment

What do we call exceptions to the exclusive rights of copyright law?


An exception is a limitation of the law, which we refer to as _____

Answers

Answer:

Fair use

Explanation:

I don't know if this is correct but Its the best option.

Please help w/ Java, ASAP!!!!

Answers

Answer:

B

Explanation:

When you have a method that is copying values from one array into another, you first have to initialize a new array which you can copy the values into. This is done by using the provided value "count".

   int [ ] nums = new int [count];

Second, you have a "for each" loop that iterates over each index in the first array, and assigns the value at that index to the same index location in the copy array. In a "for each" loop, the variable "val" represents the content of an index, not an iterated value itself. This is why we can just do this inside the loop:

  nums[ j ] = val;

That said, you still need "j" to be there and increment because we still need a tracking value for the current index in the copy array.

   int j = 0;

   for (int val: array)

   {

     copyArray[j] = val;

    j++;

   }

Third, you return the copy version of the array.

return nums;

Source:

I am currently a second year Java student.

View which is used to specify the tables fields , their data types and properties ​

Answers

Answer:

i am hina i am grade 12 C

Explanation:

my siater name os sana

Answer:

There are 2 basic views when you work in a table: Design View and Datasheet View. Design View is used to set the data types, insert or delete fields, and set the Primary key.

Hope it helps..

Have a great day : )

Which one of these is NOT a function of an operating system? *

Managing computer hardware
Managing computer software
Allowing humans to talk to the computer
Performing quick calculations

Answers

Answer:

Allowing humans to talk to the computer

Explanation:

the operating system manages the computer hardware and software

and it also allows the ALU to perform quick calculations

In which TWO cases would you need to format a cell in a spreadsheet that contains a number? to make sure a formula includes it in calculations to change its appearance to make it easy to visually locate it to ensure no-one can use the number in calculations to ensure no-one can hide the column that contains it

Answers

Answer:

to make sure a formula includes it in calculations to change its appearance to make it easy to visually locate it

Explanation:

Microsoft Excel is a spreadsheet application used for data analysis and visualization. The worksheet of the excel file is tabular with rows and columns. A single block of the worksheet is called a cell and holds a single item located by the row and column label.

The particular cell can be referenced in a formula using the absolute reference operator '$' with the syntax "$column-label $ row-number". The background of the cells can also be formatted to have a different color.

describe a tsunami when it is far from the coast

Answers

I hope it is helpful for you ......

Mark me as Brainliest ......

Tsunamis are marine phenomena, created by the abrupt displacement of large amounts of water into an aquatic formation. Tsunamis manifest as waves, which travel in the deep waters of the oceans at an average speed of 756 kilometers per hour.

While in deep water the tsunami, due to its characteristics there, is not considered a serious danger to the floating structures, reaching the shores has particularly devastating consequences.

Learn more in https://brainly.com/question/15964056

What kind of loop should be used in a game where the user is guessing a secret code and the message"guess again" appears until the user guesses correctly?

Answers

Answer:

While loop

Explanation:

It should be noted that the number of times which the computer will ask the user to take a guess is not known.

When we have a condition like this, the while loop (or in some programs; the do-while loop) is to be used.

To further back my point, see the following program in python.

secret_code = 1234

user_guess = int(input("Take a guess: "))

while user_guess != secret_code:

    user_guess = int(input("guess again: "))

print("You guessed right")

The above program will keep asking the user to take a guess until the user enters 1234.

This may or may not be possible with a for loop.

Is the PS5 a W or L? Would you still play on the PS4 more then the Ps5?

Answers

W but PS4 is my favorite

Answer:

HMMM I dont know because if the ps4 has the horizon game then sure but if nit ps5 because that game looks sick

Explanation:

You are embedding a video in your Webpage. What three formats should you specify in the source
element to ensure that most browsers and devices can access your video?
a
b
MP4, MP3 and Wav
WebM, Ogg and Wav
MP4, MP3 and Ogs
MP4, WebM and Ogg
с
d
Next Page
Back

Answers

Answer:

d

Explanation:

Complete the following sentence by choosing
the best answer from the list below.
enables information to be viewed in
an easily understandable format.
O An output device
O An input device
O A hard disk
O A raw data device

Answers

Answer:

The correct answer is Option 1: an output device.

Explanation:

A computer is an electronic machine that works according to data and instructions given to it.

The data is the input and information is the output.

Input devices are used to take input and output devices are used to display the results of processing as output.

From the given options, An output device is the one which enables the information to be viewed in easily understandable format.

Hence,

The correct answer is Option 1: an output device.

Answer:

Output device

Explanation:

A flashing symbol that allows you to input text.

A. Cursor

B. Mouse

C. Search Engine

D. Text Box

Answers

The correct answer is A. Cursor

Answer:

A. Cursor.

Explanation:

If you read the answer choices carefully, none of them fit in with the "flashing symbol" category, even though some of them might allow you to input text. However, you have used a computer before to type out text, just like how you typed this question to Brainly. Therefore, you should also know how a cursor acts. It flashes and allows you to input text as well.

Therefore, A is the correct answer to this question.

Hope this helped!

~Jinachi~

Consider the following code: x = 5 x = x * 3 print (x) What is output

Answers

Answer:

Output: 5

Explanation:

It will print 5 on the screen

What process renders high-level programming code into usable code for the CPU?

Answers

Answer:

Compilation

Explanation:

The compiler links your code and assembles it and compiles it to a binary file. For more information you can find it on or the internet

When comparing systems software and application software, what is the main difference?

Answers

Answer:

it is a

Explanation:

i did the test

HEEEEELPPP!!!BRAINLIEST!!! THIS IS URGENT!!!

Read the following code:

count in range(80):
leo.forward(count * 2)
leo.left(count + 2)

There is an error in the for loop. What should be fixed?

Add a colon to the end of the statement
Begin the statement with the proper keyword to start the loop
Place the loop condition outside the parentheses
Replace the parentheses around the range with quotation marks

Answers

Answer:

Begin the statement with the proper keyword to start the loop

Explanation:

Given

The code segment

Required

Fix the code

The first line of the code segment is meant to be a for loop, but it does follow the right syntax.

This is so because the for keyword is missing.

The first line should be corrected and replaced with:

for count in range(80):

Hence, option (b) is correct

define input hardware​

Answers

It’s a piece of hardware (you can touch it) that changes something on the screen. Examples are a keyboard putting letters on the screen or a mouse moving the cursor

a man takes 30 step to cover 18 metre l,how many step he will needed to cover 3003m distance​

Answers

he will need to take 5,004 steps to cover 3003m distance
3003/18=166.8
166.8 x 30=5004
Answer is 5004

Where does the revolver get the IP address of a site not visited before?

the file server

the name server

the IP provider

the print spooler

Answers

Answer: The name server

Explanation:

Nameservers are part of a large database called the Domain Name System (DNS), which acts like a directory for devices and the IP addresses attached to them. What nameservers do is use this information to translate domain names into numerical IP addresses – the language our computers understand

What are 3 similarities and 3 differences between live theatre and film/videos -Drama Class

Answers

Differences-
1. Theatre is live. Film has been captured in the past. We only see after the making process is done.

2.You have chance for improvement in each theatre shows but its impossible in Films. Once film is done its done.

3.Normally Theatre is cheaper, films are costly.

Similarities-

1.Theatre and films both are arts, so many varieties of arts melt into theatre or film to make it happen.

2.Theatre and films both are very effective medium of communication.

3.Theatre and films both are considered as great form of Entertainment.
Other Questions
How is the Oxford University study different from past studies on the effects of video games?AIt included measurements of game playing time as well as gamers' experiences.BIt used different mental health and mood metrics than previous studies.CIt included device data provided by game companies.DIt used popular video games rather than those built for the study. Two resistors are used in an experiment. Resistor 1 had a resistance of 4 ohms and resistor 2 has a resistance of 2 ohms. Which resistor will have the bigger current flowing through it if the potential difference is constant PLEASE HELP.Ill mark you brainliest if its right Translate the phrases to algebraic expressions.The sum of 8 times a number and 3 who is presedent of USA Please see screenshot What is the slope of the linear function represented inthe table? Please help me 14 points! answer me these riddles three if correct i will give brainliest1. what cant you keep until you give?2. If a man has a bee in his hand what's in his eye3.What do you call a room with no windows or doors? Evolution of the atmosphereDescribe and explain how the earths atmosphere evolved. Y-4x=9 in standard form please show your work The Compromise of 1850 allowed certain territories to use popular sovereignty to determine whether the territory would be free or slave. This decision applied to much of the land gained from the War of 1812American RevolutionU.S.-Mexican WarCivil WarPlease awnser this one ASAP What kind of cell has a nonspontaneous voltage?An electrolytic cellA dry cellA wet cellA voltaic cell DO ALL OF THIS RIGHT NOWWWW INNUDUJJXO,XSL,SOKJ757N&3K8YEE HAWW Merle wants to change the formatting of all bold cells to be non-bolded. Shania wants to copy the cell color,border, and font from cell E12 to all of column D. Which best describes what each person should do?A. Merle should use Find and Replace, and Shania should use the Format Painter.B.Merle should use the Rules Manager, and Shania should use Find and Replace.C.Merle should use the Format Painter, and Shania should use the Rules Manager.D. Merle should use the Format Painter, and Shania should use Find and Replace. Plz help!!!!Kinda in a hurry to catch up on biology rn anything can help!!! a.GroupThe intervals of the horizontal axis.b. The break in the vertical axis.c. The break in the horizontal axis.d. The intervals of the horizontal axis are not labeled correctly. QUESTION 5How does a plant cell split into two new cells?Plants cells do not go through cytokinesis A cleavage furrow formsA cell plate formsThe cell pinches in Federal, Social Security, and Medicare are all types of taxes, true or false? c. As the price of the bananas decreased by 15%, 3 more bananas were bought for 100 dollars. What is the price of bananas per dozen at present