rand() function with a linked list

Hey im trying to generate a linked list with random items/keys, only when i get my list, all the items are the same random number, and all the keys are all similar too. what am i doing wrong here....?
linked lists don't have keys..

what am i doing wrong here....?
what are you doing at all? my guess is that you're calling srand before each rand (you should only call it once), though it could be anything..
Topic archived. No new replies allowed.