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
Ivahew [28]
3 years ago
12

Write a program to solve the selection problem. Let k = N/2. Draw a table showing the running time of your program for various v

alues of N.
Computers and Technology
1 answer:
Brums [2.3K]3 years ago
4 0
So here is the code in Python:

n = 0.00 #this is a float because there are some numbers that are decimals.

while n < 20: #n which is 0.00 and while it is lower than 20 if runs the code below
n = n + 1 #it will add 1 to n everything it runs the code.
k = n / 2 #it will divide whatever n is everytime by 2
print(str(n) + '/2: ') # it's printing the number it's on
print(k) # prints the answer for the n.

You can change n to add by any, make n any num instead of 0.00 and you can change the while condition from n < 20 to any other logical statement. If you want to get creative you can take 2 inputs for numbers and make one of them the starting number and other one is the ending number. Also make sure to make n a number lower than you starting point because if you set n as your starting point then it will skip it.

You might be interested in
HELP I SUCK IN THIS HELP!!!!! ​
Alona [7]

Answer:

I think it's print(5**3)

8 0
2 years ago
Dams provide what kind of energy ?
Leto [7]
Water energy to supply anything
6 0
3 years ago
Read 2 more answers
Define additional characteristics such as font weight or style for an html tag
Bas_tet [7]
<span>Define additional characteristics such as font weight or style for an html tag:
- attributes</span>
4 0
3 years ago
What are two best practices for creating ads? (Choose two.) Select All Correct Responses Implement one ad per ad group per keywo
salantis [7]

The two best practices for creating ads are:

  • Include three to five ads and at least three extensions in each ad group.
  • Optimize the campaign’s ad rotation for clicks or conversion actions.

<h3>How do one Create one responsive search ad per ad group?</h3>

In any ad group, one need to have at least a single responsive search ad.

Note that this will help to optimize one's performance, and as such, the two best practices for creating ads are:

  • Include three to five ads and at least three extensions in each ad group.
  • Optimize the campaign’s ad rotation for clicks or conversion actions.

Learn more about ads from

brainly.com/question/1658517

#SPJ1

5 0
2 years ago
A single instruction carried out by a computer is called a what?
pochemuha

Answer:

in computer science, an instruction is a single operation of a processor defined by the instruction set

Explanation:

if you need anymore help let me know :)

6 0
3 years ago
Other questions:
  • A pacing calendar is provided to students so they can:
    8·2 answers
  • Julio is the department head for his company's customer service department. His staff has complained that they spend countless h
    13·2 answers
  • You disassemble and reassemble a desktop computer. when you first turn it on, you see no lights and hear no sounds. nothing appe
    11·2 answers
  • A cooler with heat pipes, which contain a small amount of liquid that becomes a vapor when heated, allowing heat to be drawn awa
    10·1 answer
  • It is always better to run over and give more information when you are giving a presentation versus quitting on time.
    11·2 answers
  • True or False <br><br> Rootkits are only made by black-hat hackers.
    8·1 answer
  • Which situations are better suited to an indefinite (while) loop? Select 3 options.
    5·2 answers
  • What feature is available to add a suggestion in the margin of someone else's document?​
    15·1 answer
  • What do you do when ur grounded from all electronics and can't go outside and have t clean all day
    10·1 answer
  • This question involves the creation and use of a spinner to generate random numbers in a game. a gamespinner object represents a
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!