donnemartin / donnemartin/interactive-coding-challenges

"Implement n stacks using a single array" solution uses 2 arrays

Open
#220 0 comments 0 reactions 0 assignees View on GitHub
needs-review
Dominant language
Python
Stars
31.8k
Forks
4.7k
PR merge metrics
No merged PRs in 30d

Description

Why not include the stack pointer at the top of each stack so you can do this with a single num_stacks * (stack_size + 1) array?

Also, it is not clear why abs_index is part of the interface (as that is not part of the stack interface). Its purpose should be made clear in the challenge notebook.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.