Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yeshwanth-3085/stack-header-file-for-c
https://github.com/yeshwanth-3085/stack-header-file-for-c
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/yeshwanth-3085/stack-header-file-for-c
- Owner: Yeshwanth-3085
- Created: 2022-10-28T17:53:18.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-09-21T17:34:58.000Z (3 months ago)
- Last Synced: 2024-10-24T09:29:15.958Z (about 2 months ago)
- Language: C
- Size: 12.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Stack-Header-File-for-C
This header file requires stdio.h & stdlib.h header files to be present in your compiler to work properly.
This header file can perform 9 Operations:
1) Creating a Stack { stack CreateStack(int Capacity); },
2) Query of Capacity of the Stack { int CapacityOfStack(stack Stack); },
3) Status of the Stack { void StatusOfStack(stack Stack); },
4) Push an element into the Stack { stack Push(stack Stack); },
5) Pop an element from the Stack { stack pop(stack Stack); },
6) Peek of the Stack { void Peek(stack Stack); },
7) Displaying all the elements of the Stack { void DisplayStack(stack Stack); },
8) Flushing all the elements of the Stack { stack FlushStack(stack Stack); },
9) Freeing the Stack { void FreeStack(stack Stack); }.
WARNING: Don't forget use the FreeStack() function at the end of your program,
as this header file uses DMA (calloc()) method to allocate memory dynamically
which needs to be freed after the execution to prevent memory leak.