changeset 27 | 81a574d60c15 |
parent 9 | c3fecc82ade6 |
child 29 | 7abf6146898e |
26:d227047a3e88 | 27:81a574d60c15 |
---|---|
17 typedef struct T T; |
17 typedef struct T T; |
18 |
18 |
19 T *make_list (int elements, int rand_max) |
19 T *make_list (int elements, int rand_max) |
20 { |
20 { |
21 int i; |
21 int i; |
22 |
|
22 T *t; |
23 T *t; |
24 |
|
23 T *actual; |
25 T *actual; |
26 |
|
24 T *first = NULL; |
27 T *first = NULL; |
25 |
28 |
26 srand (time (NULL)); |
29 srand (time (NULL)); |
27 |
30 |
28 if ((t = malloc (sizeof (T) + 1)) == NULL) { |
31 if ((t = malloc (sizeof (T) + 1)) == NULL) { |