Reference no: EM13696576
Question: Assume you have two algorithms, A and B, both of which perform the same function, although their implementations differ. Assume that algorithm A has a running time of O(N3 + 2N2 + 6N + 3) and algorithm B has a running time of O(6N2 + 4N + 10).
Also suppose that the value of N is restricted to the set of Natural numbers, including 0; i.e., {0, 1, 2, 3, ...}.
Answer the subsequent questions:
Part 1: Assuming the test conditions are equal for both algorithms, which algorithm should be most efficient when N is arbitrarily large (i.e., you can select N to be as large as you want it to be)?
Part 2: Assuming the test conditions are equal for both algorithms, which algorithm should be most efficient when N is arbitrarily small (i.e., you can choose N to be as small as you want it to be)?
Part 3: Assuming the test conditions are equal for both algorithms, at what value of N might both algorithms be expected to operate with the same efficiency?
Solve these parts in details and provide examples to support your rationale.
|
Should the cio or cto report to the company president
: Contact at least three people at your school or a nearby company who use information systems. List the systems, the position titles of the users, and the business functions that the systems support.
|
|
Sum of all odd numbers between a and b
: The sum of all odd numbers between a and b (inclusive). Where a and b are read in by the user - Can you find the error in this code.
|
|
Represent 99 and -99 in 2s complement format
: what are the largest(positive) and smallest (negative) integers a word can represent - Represent 99 and -99 in 2's complement format.
|
|
Determine the precise big-oh values
: Determine the precise Big-Oh values for each of the following code samples, based on the number of statement executions - Remember to consider each statement in compound statements separately.
|
|
Which algorithm should be most efficient
: the test conditions are equal for both algorithms, which algorithm should be most efficient when N is arbitrarily large (i.e., you can select N to be as large as you want it to be)?
|
|
Prepare an app that calculates the product of a series
: Prepare an app that calculates the product of a series of integers that are passed to method product using a variable-length argument list.
|
|
Translate the given code into mips64 assembly language
: you can use the instructions 'blt' (branch on less than), 'ble' (branch on less or equal), 'bgt' (branch on greater than) and 'bge' (branch on greater or equal) - Translate the given code into MIPS64 assembly language.
|
|
Write a statement that prints the message recall
: Clunker Motors Inc. is recalling all vehicles from model years 1995-1998 and 2004-2006. Given a variable modelYear - Write a statement that prints the message "Recall" to standard output if the value of modelYear falls within those two ranges.
|
|
Learn as much as possible about that ip address
: Using tools that are freely available in the Web, learn as much as possible about that IP address (Domain name, owner, physical location, address, etc.)
|