Skip to content

Conversation

@sneha-tambade
Copy link

No description provided.

@super30admin
Copy link
Owner

  • MinStack: Your implementation is excellent. It correctly maintains two stacks to achieve O(1) time complexity for all operations. The comments are clear and the code is easy to understand.
  • MyHashSet: While your solution works, it uses a BitArray which is not as space-efficient as the double hashing technique in the reference solution. Consider implementing the double hashing approach to optimize space usage. Your understanding of the need for linked lists and hashing is good, and I encourage you to explore that further.

Overall, your solutions are correct and well-structured, but the MyHashSet could be improved for better space efficiency.

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