#include #include typedef int ElementType; struct NodeStruct { ElementType elem; struct NodeStruct* next; }; typedef struct NodeStruct NodeType; void insert(NodeType** node, ElementType elem) { NodeType* newNode; newNode = malloc(sizeof(newNode)); newNode->elem = elem; newNode->next = (*node); (*node) = newNode; } void print(NodeType* list) { printf("elem: %d\n",list->elem); print(list->next); } int main() { NodeType* list = 0; insert(&list,10); insert(&list,11); insert(&list,12); print(list); }