void appendToList(int list [], int data) {
int temp[(sizeof list/sizeof int)+1] = list;
};
It seems to be a problem with the adding one.
I thought that I should be able to create an array with 1 more space than the original but it throws this error.
The second error (line 26) is fatal.
trial.c:27:22: warning: 'sizeof' on array function parameter 'list' will return size of 'int *' [-Wsizeof-array-argument]
27 | int temp[(sizeof list/sizeof int)+1] = list;
| ^~~~
trial.c:26:23: note: declared here
26 | void appendToList(int list [], int data) {
| ~~~~^~~~~~~
trial.c:27:34: error: expected expression before 'int'
27 | int temp[(sizeof list/sizeof int)+1] = list;
| ^~~