Walk me through how you would implement a basic custom data structure, such as a stack or a queue, from scratch.