aboutsummaryrefslogtreecommitdiff
path: root/leetcode.h
diff options
context:
space:
mode:
authorJack Sangdahl <[email protected]>2025-08-27 12:45:33 -0600
committerJack Sangdahl <[email protected]>2025-08-27 12:45:33 -0600
commit4552bcf5a4a356415e248dee3b201f0cea7205bb (patch)
tree9868465918c6a6841b84cd14d66923b993dd9d62 /leetcode.h
parentf549305fb5ca531d29dce6c2c091560f44190443 (diff)
downloadleetcode-4552bcf5a4a356415e248dee3b201f0cea7205bb.tar.gz
leetcode-4552bcf5a4a356415e248dee3b201f0cea7205bb.zip
chore: Refactor two_d_arr_init function
Return a pointer to a new struct, rather than initialise objects in an existing struct
Diffstat (limited to 'leetcode.h')
-rw-r--r--leetcode.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/leetcode.h b/leetcode.h
index cc17fc2..fd17b7c 100644
--- a/leetcode.h
+++ b/leetcode.h
@@ -35,8 +35,8 @@ struct Node {
struct Node **children;
};
-void two_d_arr_init(struct two_d_arr *obj, int row_size, int col_size,
- int arr[row_size][col_size]);
+struct two_d_arr *two_d_arr_init(int row_size, int col_size,
+ int arr[row_size][col_size]);
void two_d_arr_free(struct two_d_arr *obj);
struct ListNode *listnode_create(int val);