int input = 0; Number *tmp = NULL; start = NULL; for (input = 1; input < argc; input++) { if (start == NULL) // start being NULL indicates an EMPTY list { start = (Number *) malloc(sizeof(Number)); // allocate new Number start -> value = atoi(argv[input]); // assign input into Number start -> next = NULL; // assign next value as NULL tmp = start; // tmp is pointing to the end of our list } else // non-NULL start means a populated list { tmp -> next = (Number *) malloc(sizeof(Number)); // allocate new Number, attached at end of list tmp = tmp -> next; // advance tmp pointer to newly allocated Number tmp -> value = atoi(argv[input]); // assign input to new Number in list tmp -> next = NULL; // set next to NULL (should be nothing after end of list) } }