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
kumpel [21]
3 years ago
6

Suppose for the worst case, given input size n: Algorithm 1 performs f(n) = n2 + n/2 steps Algorithm 2 performs f(n) = 12n + 500

steps What is the smallest value of n for which algorithm 2 will be faster than algorithm 1?
Computers and Technology
1 answer:
melomori [17]3 years ago
6 0

Answer:

29

Explanation:

for n=28:

--------------

Algorithm 1 performs f(n) = n2 + n/2 = 28*28 + 28/2 = 798

Algorithm 2 performs f(n) = 12*28 + 500 = 836

for n=29

--------------

Algorithm 1 performs f(n) = n2 + n/2 = 29*29 + 29/2 = 855.5

Algorithm 2 performs f(n) = 12*29 + 500 = 848

so, for n=29, algorithm 2 will be faster than algorithm 1

You might be interested in
Which slide elements must claire use to enhance her presentation?
Crank

The answer for the 1st blank is text.


6 0
3 years ago
Read 2 more answers
What does "CPU" stand for?
MrMuchimi
Central processing unit
7 0
3 years ago
Read 2 more answers
A network utilizes a network access control (NAC) solution to protect against malware. When a wired or wireless host tries to co
Inessa [10]

Answer: Posture assessment

Explanation:

Posture assessment, also refers to posture validation and it is when somw set of rules are applied to the posture data which then gives an assessment of the trust level which can be placed in th e endpoint.

Posture assessment has to do with how the system security is evaluated based on the applications and the settings.

3 0
3 years ago
9. Question
Gennadij [26K]
A server stopped provide service to 100 users
5 0
2 years ago
2) The CPU is made from a silicon<br>b) Chip<br>C) pendrive<br>a) Steel<br>​
Aleks [24]

Answer:

b

Explanation:

a cpu is made from silicon chip

5 0
2 years ago
Other questions:
  • Do we have to use intersection?
    6·1 answer
  • A Web ____ is a software program that retrieves the page and displays it. Select one:
    5·1 answer
  • What US federal agency publishes safety standards for business and industry?
    5·1 answer
  • What is displayed on the console when running the following program? class Test { public static void main(String[] args) { try {
    10·1 answer
  • To view the results of a query, open it by pressing and holding or right-clicking the query in the navigation pane and tapping o
    10·1 answer
  • Consider the following program where the zu format specifier is used to display as an integer the result of sizeof. #include #in
    11·1 answer
  • A _____ refers to a product or service, such as a technical report, a training session, a piece of hardware, or a segment of sof
    12·2 answers
  • Display all the natural numbers from 1 to 100 that are exactly divisible by 3 and 7 using FOR … NEXT. Without using Mod
    7·1 answer
  • Flash drive DVD and hard drive are all examples of
    6·2 answers
  • In your own opinion how comes the surface grinding machine is called a highly accurate machine tool?​
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!