https://github.com/mburakeker/store-multiple-stacks-in-array
https://github.com/mburakeker/store-multiple-stacks-in-array
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/mburakeker/store-multiple-stacks-in-array
- Owner: mburakeker
- Created: 2021-03-21T20:28:53.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2021-03-21T20:39:20.000Z (about 4 years ago)
- Last Synced: 2025-01-30T18:46:21.120Z (4 months ago)
- Language: C#
- Size: 7.81 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
In this task, I created ArrayOfStacks with following properties:
* Stack[] stackArray
* int[] tops as storing the top indexes of each stack
* stackCount with the expression of stackArray.Length
Adding a new stack requires resizing so Add(Stack stack) method resizes stackArray and sets the highest index of stackArray to given stack input.
T this[int index] allows you to get the element at given index.