logo

Crowdly

Browser

Add to Chrome

FIT1008-FIT2085 Fundamentals of algorithms - S1 2025

Looking for FIT1008-FIT2085 Fundamentals of algorithms - S1 2025 test answers and solutions? Browse our comprehensive collection of verified answers for FIT1008-FIT2085 Fundamentals of algorithms - S1 2025 at learning.monash.edu.

Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!

Given an algorithm taking a string as input, with respect to what should its complexity be analysed?

0%
100%
0%
View this question

Estimate the complexity of the following function in terms of the input integer n:

def mystery(n: int) -> None:

result = 0

for i in range(10000000):

j = n

while j > 2:

result += i

j /= 2

return result

0%
0%
0%
100%
View this question

Can Bubble Sort be made incremental?

0%
0%
View this question

Is Selection Sort Stable?

0%
100%
View this question

Given that there are n items in a list to sort, what's the maximum number of swaps for Bubble Sort per iteration?

0%
0%
0%
0%
View this question

Given an algorithm taking a collection of n items (each item being of fixed size) as input, with respect to what should its complexity be analysed?

0%
0%
100%
View this question

How many times will the marked line in the following code run when the input integer is n?

def mystery(n):

stamp = 0

if n <= 0:

return 0

else:

for i in range(n):

for j in range(n):

stamp += j # This line

return stamp

Answer in terms of n

0%
0%
0%
0%
View this question

What is the purpose of this function? 

def cipher(my_array):

sherlock = my_array[0]

watson = my_array[-1]

moriarty = 0

for villain in my_array:

if villain > sherlock:

moriarty += 1

elif villain < watson:

watson = villain

return sherlock, moriarty

0%
0%
0%
0%
View this question

Consider the following implementation of a class for a Monash student: 

class Student:

def __init__(self, name, stud_id):

self.name = name

self.stud_id = stud_id

def __le__(self, other):

# TODO: Finish implementation

0%
0%
0%
0%
View this question

What will be the returned value from the following function: 

def mystery(lst):

bango = []

for unicorn in lst:

if unicorn % 2 == 0 or str(unicorn) > "2":

bango.append(unicorn)

return len(bango)

when the value of lst is [0, 1, 2, 3, 3, 5, -0, 6, 7, -8]

View this question

Want instant access to all verified answers on learning.monash.edu?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome