Overview Write a program that reads an integer from the user and then prints the Hailstone sequence starting from that number "What is the hailstone sequence?" you might ask. Well, there are two rules: • If n is even, then divide it by 2 • If n is odd, then multiply it by 3 and add 1 Continue this sequence until you hit the number 1.​

Overview Write A Program That Reads An Integer From The User And Then Prints The Hailstone Sequence Starting

Answers

Answer 1

n=int(input("Enter number: "))

while n != 1:

   print(n)

   if n%2==0:

       n//= 2

   else:

       n = (n*3)+1

print(n)

I wrote my code in python 3.8. If you want to print the 1, keep the last line of code otherwise delete it.


Related Questions

On December 9, 1698, computer inventor Douglas Engelbart demonstrated many new computing technologies, including the computer mouse. His demonstration was so important that it became known as “The Mother of All Demos”. It would be at least two decades before some of the technologies he demonstrated saw widespread use, but all of them are used by people today. Here is a list fo some of Engelbart’s technologies. Which ones do you use today? The computer mouse, video conferencing hypertext links, word processing, or collaborative real-time editing

Answers

Answer:

all of them

Explanation:

Answer: All trust guy above

Explanation:

.

What is the base of a number system?

A.
the minimum number of digits needed to represent a number in that system
B.
the place value of the leftmost digit in numbers written in that system
C.
the place value of the rightmost digit in numbers written in that system
D.
the number of symbols used to represent numbers in that system

Answers

Answer:

A

the minimum number of digits needed to represent a number in that system

Ugh these are hard questions

Answers

9 is B, and 10 is D I think ... brainliest pls

Propose a list of five milestones that would be reasonable in a mid-project prototype phase of a video game development project (any genre).

Answers

Answer:

Five milestones of a game development process are prototype, vertical slice, pre-alpha, alpha, and beta.

Explanation:

Game development is the process of creating or producing a functional bug-free game. The development process hits several milestones throughout its three stages or processes. These milestones are prototype, vertical slice, pre-alpha, alpha, beta, and gold master.

what is the mass of a cookbook

Answers

Answer:

it varies on the size of the cookbook

Explanation:

Which tool would you use to display only the
breeds that are good with kids? (Filter, sort, locate)
Which filter parameter would display only rows 3
and 6? (No, yes, less than 100)
Which tool would organize the list from most
preferred to least preferred? (Sort, locate, filter)
Which tool would organize the list from lightest
breeds to heaviest breeds? (Sort, locate, filter)
(A simple parameter, multiple parameters) is/are needed to organize
the list so that it shows only dog breeds that are
good with kids and less than 25 inches tall.

Answers

Answer:

Which tool would you use to display only the breeds that are good with kids?:Filter

Which filter parameter would display only rows 3 and 6?: No

Which tool would organize the list from most preferred to least preferred? Sort

Which tool would organize the list from lightest breeds to heaviest breeds?: Sort

Multiple Parameters: is/are needed to organize the list so that it shows only dog breeds that are good with kids and less than 25 inches tall.

Explanation:

From the spreadsheet, the tool that would be used to display only the breeds that are good with kids is known aa a filter.

Spreadsheet

Based on the spreadsheet that's shown, it should be noted that the filter parameter would not display only rows 3 and 6.

A tool that can be used to organize the list from most preferred to least preferred is sort tool. This is essential for sorting.

Also, it can be used to organize the list from lightest breeds to heaviest breeds.

In conclusion, the multiple parameters are needed to organize the list.

Learn more about spreadsheet on:

https://brainly.com/question/25879801

How will you define a text?

Answers

Answer:

Text refers to content rather than form; for example, if you were talking about the text of "Don Quixote," you would be referring to the words in the book, not the physical book itself. Information related to a text, and often printed alongside it—such as an author's name, the publisher, the date of publication, etc.—is known as paratext.

The idea of what constitutes a text has evolved over time. In recent years, the dynamics of technology—especially social media—have expanded the notion of the text to include symbols such as emoticons and emojis. A sociologist studying teenage communication, for example, might refer to texts that combine traditional language and graphic symbols.

Explanation:

I Hope it help

Erin would like to add a photo to a presentation. However, she only has the printed copy of the photo. She does not have a digital copy. What should Erin do?

Answers

Answer:

Erin should scan the photo.

Took it on Edge <3

Answer:

Erin should scan the photo.

Explanation:

That´s what I thought :)

Select the correct answer from each drop-down menu. What are the effects of emerging technology? has brought the internet to almost every location around the world. has led to the proliferation of on-the-go computing. Reset Next​

Answers

Answer:

The correct answers are:

Wireless web

Mobile computing

Explanation:

I got it right on the Edmentum test.

Wireless web has brought the internet to almost every location around the world. Mobile computing has led to the proliferation of on-the-go computing.

What is technology?

Technology, or as it is sometimes referred to, the modification and manipulation of the human environment, is the application of scientific knowledge to the practical goals of human life.

A catchall phrase for unrestricted access to the Internet and other services like email and messages.

The wireless Web is made up of public and private hotspots, cellular Internet access, and all other fixed or mobile wireless access services.

In human-computer interaction known as mobile computing, a computer is expected to be carried around while being used, allowing for the transmission of data, speech, and video.

Mobile hardware, mobile software, and mobile communication are all components of mobile computing.

Thus, these are the effects of emerging technology.

For more details regarding technology, visit:

https://brainly.com/question/9171028

#SPJ5

Which type of data is is usually collected as numerical data that can be presented in a graph or chart?

Answers

Answer:

Quantitative data

Explanation:

Quantitative data is information about quantities; that is, information that can be measured and written down with numbers. Some other aspects to consider about quantitative data: Focuses on numbers. Can be displayed through graphs, charts, tables, and maps.

Zareen used a school computer to create a fake
website where she posted pictures and rude
comments about her former friend.
What consequences could she face from school
officials for her actions? Check all that apply.
She could have her technology privileges taken
away.
She could face a severe financial penalty.
She could spend time in a juvenile detention facility.
She could face detention or suspension.
O She could be forbidden from attending school social
events.
She could be denied access to certain websites.

Answers

Answer: She could have her technology privileges taken away, She could face detention or suspension, She could be forbidden from attending school social events, She could be denied access to certain websites.

Explanation: ADEF on Edge 2021

The  consequences could Zareen  face from school are-

She could have her technology privileges taken away.She could be denied access to certain websites.She could face detention or suspension.What is a computer?

A computer is referred to as an electronic device that is used to perform arithmetic and logical operations quickly and accurately without causing any error in the result.

In the given case, it is explained that A girl named Zareen used a school computer to post comments inappropriate and rude comments about her former friend by creating a fake website.

This shows that Zareen has violated someone's personal privacy which can result in severe actions against her so the school may restrict her to use this kind of website.

As she disturbs someone's personal or social image it can cause her with suspension from school. The school may restrict her to use any kind of technology due to her immature and rude behavior.

Learn more about computers, here:

https://brainly.com/question/1380748

#SPJ5

plz help im timed
An artist posted a picture of a painting on his website in order to sell it. Another business copied the picture and used it as a background on a website without giving credit to the artist. This action is most strongly related to which aspect of life?

culture

society

ethics

economy

Answers

Answer:

i believe C. Ethic

Explanation:

Ethics or moral philosophy is a branch of philosophy that "involves systematizing, defending, and recommending concepts of correct and wrong behavior". The field of ethics, along with aesthetics, concerns matters of value, and thus comprises the branch of philosophy called axiology.

What are the most important considerations when comparing computer systems? Check all of the boxes that apply.

the type of mouse
the type of keyboard
computer speed
amount of storage

Answers

C and D



Explanation:




How does using list make a program easier to develop and maintain

Answers

Answer:

Kindly check explanation

Explanation:

List is a built in data type used in programming languages, it consists of data enclosed in square brackets []. A llust has different functionality most of which makes development and maintenance of programs easier. Some of the core usefulness of a list include its ability to incorporate different types of data such as strings, int, floats and so on in just a single list. Lists also be created in a list (called list of lists). Deletion of list elements, searching through elements in a list, replacement of values in the list and appending new data values to an already existing list. Lists also provides an easy way to loop through elements embedded in them and list operations can be carried out simultaneously.

Lists are simply data types that can hold multiple values of different data types using one variable.

Usefulness

As its definition implies, it is used to hold different values.

Take, for instance:

num1 = 5

num2 = 10

The above statements can be combined into a list as follows:

num[] = [5,10]

The data types of the values in the list may not be the same.

The following is another correct definition of a list

person_details = ["Kaitlyntoohey",29,45.6]

The above list contains a string, an integer and a float datatype.

Lastly, a list can also contain a list.

Read more about lists at:

https://brainly.com/question/14284563

Rebecca's school has planned an excursion to the nearest TV production studio. Rebecca noticed cameras on stands that send signals directly to
the production control room for collaboration with other cameras. Which camera is the production house using for recording?
OA
prosumer camera
OB
studio camera
OC.
DSLR camera
OD
Glidecam

Answers

A. Prosumer camera I think not sure tho I just know for sure it’s not B but I’m almost posting it’s A

Approximately how many tweets are posted on Twitter each day? 500 500 thousand 500 million 500 billion

Answers

Answer:

around 500 million

Explanation:

Can you guys help me with this coding assignments?

Answers

Explanation:

x ==50

while x< 100;

x -= 1

I really need help please :)

Answers

I'm sorry I don't know question 6, but question 5 is B. Who love

help me pleaseeeeeeeee​

Answers

Answer:

Git hub or. Stackoverflow has most of the answers about programming

Explanation:

Programmers will write _________ as a framework from which to write formal code.

Answers

Answer:

pseudocode

Explanation:

The used of PPE in the shop includes the following, except:
A. safety apron
B. safety goggles
B. safety helmet
D. safety net

Answers

It should be C. Safety Helmet I think

Answer:

Safety helmet is not included in PPE

The goal of a system is to


be natural or human-made

use energy

perform a task

be social or physical

Answers

Answer:

The answer is option C, which is: perform a task

Alicia is a dietitian. She gives other people suggestions for nutrition. She wants to organize a large amount of data concerning food, calories, fat grams, protein, cholesterol, and sodium. Alicia should use a _____. word processor smart card digital ink pen database

Answers

Answer:

database

Explanation:

As a dietitian, Alicia must be well-grounded with the way diet and nutrition work in relation to health and disease. So, provided she wants to organize a huge amount of data on this particular field, she should consider the use of a database. This is because the information in the database is well organized and regularly structured. It can also serve as a means of storing, retrieving, and manipulating data sets.

True or false: The Nickelodeon the first movie theater to become successful showing only films opened in Pittsburgh in 1915

Answers

Answer:

ture

Explanation:

Answer:

TRUE I THINK....................

Explanation:

A good practice when using public domain content is to

a. Credit the source
b.Get a copy of the trademark
c.Make donations when able
d.Ask for permission

Answers

Maybe try C I don’t really get it

Choose the term that best matches the definition.
v rules used by a computer network.

A. Network protocol
B. Hierarchy protocol
C. Procedure

Answers

Answer: it’s network protocol

Explanation:

Answer:

A. Network protocol

Explanation:

On Edge, it states that network protocol are, "rules used by computers in a network." Therefore, it's confirmed.

I hope this helped!

Good luck <3

Why is it important to organize your computer files?

“With a explanation”

Answers

Answer: So then every thing is not cluster together and you have everything where you can get to it faster and it just makes everything  100 times better then it not being organized :) hope this helped and if it didn't I'm so sorry

Explanation:

A key and scale are important components in what visual aid?

pie charts
line graphs
maps
diagrams

Answers

Answer:

maps

Explanation:

I hope it's help you

Search online for the various configuration processors available. Mention the brand names that are widely used.

Answers

Answer:

Some of the configuration processors that are available are:

Phenom X4: Phenom X4 is the first quad-core microprocessor family that depends on K10 microarchitecture. Phenom X4 CPUs make use of four-digit model numbers that begin with 9. The remaining three digits in the model number show relative processor performance.

Athlon: Athlon is a seventh generation x86 processor. Athlon dynamically buffers internal microinstructions at runtime. These microinstructions result from parallel x86 instruction decoding.

Sempron: The first Sempron CPUs depended on the Athlon XP architecture using the Thoroughbred or Thorton core. These models were equipped with the Socket A interface, 256 KiB L2 cache, and 166 MHz front-side bus (FSB 333). These models use different technologies and CPU socket formats.

Opteron: Opteron is AMD's x86 server and workstation processor line. It was the foremost processor to support the AMD64 instruction set architecture. The Opteron processor has an integrated memory controller that supports DDR SDRAM, DDR2 SDRAM, or DDR3 SDRAM (depending on the processor generation). This both decreases the latency penalty for accessing the main RAM and does not require a separate northbridge chip.

The brand names widely used are Intel and AMD.

The configuration processors available are

Phenom X4AthlonSempronOpteron

Intel and AMD are the two most commonly utilized brand names.

What are configuration processors?

The path through a business process or operation is represented by a processor. By selecting the Configure option with the right mouse click, you can configure a processor. A processor's type and name are automatically the same.

The computer needs both processing power and instructions, which the processor delivers. The clock speed of a processor should be your first consideration. Your computer will run faster if the clock speed is higher.

Different architectures are used to build the various CPU kinds. Processors with one, two, four, six, eight, or twelve cores are the most common types of CPUs.

Learn more about configuration processors, here:

https://brainly.com/question/10710240

#SPJ5

Tell me 2-6 computer parts that are inside a computer.

Spam answers will not be accepted.

Answers

Answer:

Memory: enables a computer to store, at least temporarily, data and programs.

Mass storage device: allows a computer to permanently retain large amounts of data. Common mass storage devices include solid state drives (SSDs) or disk drives and tape drives.

Input device: usually a keyboard and mouse, the input device is the conduit through which data and instructions enter a computer.

Output device: a display screen, printer, or other device that lets you see what the computer has accomplished.

Central processing unit (CPU): the heart of the computer, this is the component that actually executes instructions.

Explanation:

Other Questions
rationalize i)2 by3ii)52 by23iii)15 by 5iv)5 by 56plz solve in notebook Sandra is riding a water slide at her favorite water park. At the top of the slide,she has 5,000 J of gravitational potential energy. After a few seconds, she has1,928 J of gravitational potential energy. What is her kinetic energy at this point,in J? given tu ij find the length of hj Describe at least ONE explanation for the actions of the Salem villagers in 1692 that resulted in the witchcraft trials. A forest fire caused by lightening destroys an entire forest. The population of deer was drastically reduced within the forest leading to a decrease in genetic variation. This situation is an example of - Mutations Gene Flow O Genetic Drift Divergent evolution Look at this picture and choose the most logical statement that describes how La, Coline, and Fabien are related. A. La est la sur ane de Coline et Fabien. B. Coline est la sur ane de La et Fabien. C. Fabien est le frre an de La et Coline. D. Coline est la sur cadette de Fabien et La. PLEASE ANSWER ASAP !!!!! When most people immigrated to American they? Solve the inequality 2x 15 1. Which of the following is a valid consideration under the law of contract?A. Joko pays Jaa Hat RM50 to beat up the boy who has been bullying Joko'syounger brother in schoolB. Betty sells a Persian cat to Suzita for RM8,000C. Khairil offers to pay Luna RM10,000 if she can obtain the secret formula in theingredient used by Chef Wah in his famous chicken dishD. Izah agrees to pay Tok Bomoh RM2,500 if he can get rid of the spiritshaunting her house Hi! I produce proteins inside the cell. What am I? Which element is in the same period as Potassium (K) and in the samegroup as Flourine (F)?O A. Bromine (Br)O B. Oxygen (O)O C. Selenium (Se)O D. Argon (Ar) Which of the following principles underlies the interaction of individual choices? a Marginal analysis is used for "how much" decisions. b People usually exploit opportunities to make themselves better off. c Resources are scarce. d There are gains from trade. Carbohydrates are broken down in the small intestine and absorbed into the bloodstream.TrueFalse Someone help me out. Im stuck on this problem What root word means to calm or please 24 + 36= A. 3 (8+13) B. 4(6+9) C. 12 (2+3) D. 6 (4+6) a math club has 25 members,of which 11 are makes and the rest are females.what is the ratio of males to all club members? What is the difference between the weather conditions to form a hurricane and a tornado? what mesage do you think party leaders who attended the ceromy were trying to send in biden inauguration.