All pastes #505796 Raw Edit

Miscellany

public text v1 · immutable
·published 2007-05-23 19:11 UTC
rendered paste body
#include <stdio.h>

typedef struct {
    int aaa;
    int bbb;
    int ccc;
} student;

int main(int argc, char **argv, char **envp)
{
    student *a[100];
    int i;
    for(i=0; i < 100; ++i) {
        a[i] = calloc(1, sizeof(student));
        a[i]->aaa =i;
    }

    for(i=0; i < 100; ++i) {
        printf("%d ", a[i]->aaa);
    }
return 0;
}