Question: Student Name he following function supposedly creates an identical copy of a string. What's wrong with the function? char strdup (const char p chat q
Student Name he following function supposedly creates an identical copy of a string. What's wrong with the function? char "strdup (const char p chat "q strcpy (q,P) ceturn 10. What is the problem with following code? int main int *p (int malloc(sizeof iint) PNULL free(p) a 11. Below is one example used to create a thread in C. But why pthread library needs the address of thread id passed into function pthread_create? pthread create(&threads_id, NULL, &Hello world, NULL) Part 3 Filling the blanks (12 points in total, 2 points for each blank): Finish the program according the requirement. 1. The following program outputs all the positive integers which can match all the three criteria below: A. smaller than 100 B. end with digit 6 C. divisible by 3 For example, 6 and 36 can match all the criteria. void main) int i,j: for(i 0 ji 10+6; if ( printf ("id ",j) ) continue
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
