Rework PostIDs, ActivePostIDs and AuthorIDs #26

Closed
opened 2021-11-15 18:17:09 +00:00 by asdam9 · 0 comments
Owner

Rework them so that they return the count, and assign the array to the variable referenced by a parameter.

int x func(int** l, MYSQL* con)
{
	*l = array_of_num();
    
    return count(array_of_num());
}

int main(int argc, char *argv[])
{
	int *IDs;

	int count = func(&IDs, NULL);
    
    printf("There are %d IDs\n", IDs[count - 1]); 
}

Rework them so that they return the count, and assign the array to the variable referenced by a parameter. ``` int x func(int** l, MYSQL* con) { *l = array_of_num(); return count(array_of_num()); } int main(int argc, char *argv[]) { int *IDs; int count = func(&IDs, NULL); printf("There are %d IDs\n", IDs[count - 1]); } ```
asdam9 added this to the Database Handler milestone 2021-11-15 18:17:09 +00:00
asdam9 added the
correction
label 2021-11-15 18:17:09 +00:00
asdam9 self-assigned this 2021-11-16 07:47:14 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: asdam9/FoCuSSG#26
No description provided.