Skip to content

Conversation

seaweeddol
Copy link

No description provided.

Copy link

@CheezItMan CheezItMan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work Jessica, the methods work. Take a look at my 1 comment on space complexity of newman_conway. Otherwise great job.

Comment on lines +2 to 4
# Time Complexity: O(n), n = length of array
# Space Complexity: O(1)
def max_sub_array(nums)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Comment on lines +1 to 3
# Time complexity: O(n), n is num
# Space Complexity: O(1)
def newman_conway(num)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you're building an array, the space complexity is O(n).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants