Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

clarity on what this mean #25

Open
HawiCaesar opened this issue Apr 24, 2018 · 0 comments
Open

clarity on what this mean #25

HawiCaesar opened this issue Apr 24, 2018 · 0 comments

Comments

@HawiCaesar
Copy link

1. Implement a stack with a min method which returns the minimum element currently in the stack. This method should have O(1) time complexity. Make sure your implementation handles duplicates.

I can't seem to figure out what the question is asking. When implementing the stack I had it look like so
{1: 'ABC', 2: 'DEF'...}. But won't get the minimum value be 0 ? Or should we use numbers as values ? I am bit confused

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

No branches or pull requests

1 participant