FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
C/data_structures/dynamic_array/dynamic_array.h at master · SelfCodeLearning/C · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
SelfCodeLearning
/
C
Public
forked from
TheAlgorithms/C
Notifications
You must be signed in to change notification settings
Fork
0
Star
0
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
C
/
data_structures
/
dynamic_array
/
dynamic_array.h
Copy path
More file actions
More file actions
Latest commit
History
History
History
26 lines (17 loc) · 662 Bytes
Breadcrumbs
C
/
data_structures
/
dynamic_array
/
dynamic_array.h
Copy path
File metadata and controls
26 lines (17 loc) · 662 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#ifndef
__DYNAMIC_ARRAY__
#define
__DYNAMIC_ARRAY__
#define
DEFAULT_CAPACITY
1 << 4
#define
INDEX_OUT_OF_BOUNDS
NULL
typedef
struct
dynamic_array
{
void
*
*
items
;
unsigned
size
;
unsigned
capacity
;
}
dynamic_array_t
;
extern
dynamic_array_t
*
init_dynamic_array
();
extern
void
*
add
(
dynamic_array_t
*
da
,
const
void
*
value
);
extern
void
*
put
(
dynamic_array_t
*
da
,
const
void
*
value
,
unsigned
index
);
extern
void
*
get
(
dynamic_array_t
*
da
,
const
unsigned
index
);
extern
void
delete
(
dynamic_array_t
*
da
,
const
unsigned
index
);
unsigned
contains
(
const
unsigned
size
,
const
unsigned
index
);
extern
void
*
retrive_copy_of_value
(
const
void
*
value
);
#endif
Back
|
FazBrowse Home
|
New Git URL