Original Post
Hello, is there any use for linked lists or double-linked lists in gamedesign? (Just asking, for no particular reason.)
#include <vector>using namespace std;#include <stdio.h>#include <stdlib.h>#include <time.h>int main(void){ srand(time(NULL)); vector<int> vecList; for (int i = 0; i < 10; i++) { int num = rand()%100; printf("(Add..) #%d: %d\n", i, num); vecList.push_back(num); } vector<int>::iterator IntIt = vecList.begin(); int i = 0; for (IntIt = vecList.begin(); IntIt != vecList.end(); IntIt++) { int num = (*IntIt); printf("(Print) #%d: %d\n", i++, num); } system("pause");}Quote:
Original post by lightblade
I just don't know why this is in the game design forum and not the programming forum
This topic has been locked by a moderator. New replies are not allowed.
With your permission, GameDev.net uses analytics cookies to understand how people use the platform. You can accept analytics or continue with necessary cookies only. Learn more