Java代写｜2110 Assignment 2
AUTHOR
essaygo
PUBLISHED ON:
2022年2月16日
PUBLISHED IN:

This assignment is broken into 3 questions that are meant to test your knowledge of Big Oh notation and ordering as well as data structures we covered in class and their implementations.

Question 1 and 3 are worth 30% of the overall assignment mark while Question 2 is worth 40%.

Read the entire assignment carefully because there will be information and requirements you may not be familiar with.

Style: We will be requiring students to follow the Java Style guide designed by Alex that is posted in the Assignments folder in the content section of Brightspace. This will be an important component of the course and when you enter the industry and can follow a style guide, you will thank us. The assignments will follow this style guide strictly.

Assumption: All input given will follow exactly what the questions state or are asking for; there will be no reason to error check in this assignment.

## Question 1 (12 points)

First look at each function below and place its time complexity in the space provided in the Big Oh notation you learned. Next, order the functions from least time complexity to most, making the functions at the start of the list the most efficient. If there are doubles of the same time complexity, you may place them in any consecutive order. Here are some examples:

Order: C, A, B is correct or C, B, A is also correct

i) Please note that the submitted file should be A2Q1.pdf and that we require pdf format. You should refresh your basic logarithmic rules. Use the following table as your submission:

ii) Order the functions in ascending order (least efficient to most efficient).

Put your ordered list in the following format or it won’t be marked: A, C, F, I, J, B, D, G, E, H

## Question 2 (20 Points)

First look at each piece of code or pseudo code below and place its time complexity in the space provided in the Big Oh notation you learned. Next, order each piece of code or pseudo code from least time complexity to most, making the code at the start of the list the most efficient. If there are doubles of the same time complexity, you may place those doubles in any consecutive order and they will be considered correct. See Question 1 for format information.

i) Please note that the submitted file should be A2Q2.pdf and that we require pdf format. Use the following table as your submission:

You may also like: