Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Multidimensional linked lists

Name: Anonymous 2011-12-23 9:01


namespace Multidimensional {
        Template<class T> class List; // To allow pointers to lists
        Template<class T> class List {
                List<T> *Up;
                List<T> *Down;
                List<T> *Left;
                List<T> *Right;
                T Data;
        public:
                T Element(unsigned int x, unsigned int y) {
                        // To be defined later. I'm sleepy
                }
                void InsertElement(T data, unsigned int x, unsigned int Y) {
                        // To be defined later. It's six in the damn morning!
                }
                List() {
                        Up    = NULL;
                        Down  = NULL;
                        Left  = NULL;
                        Right = NULL;
                }
        };
};


How would you make a multidimensional linked list /prog/?

Name: Anonymous 2011-12-23 9:18

You mean a directed graph?

Name: Anonymous 2011-12-23 9:28

struct Node {
    void *this; // contents of the node
    int dimensions; // number of dimensions
    struct Node *nodes; // array of next nodes in all the dimensions
};


Note that the number of dimensions could even change from node to node, though I don't see anything useful in that.

Name: Anonymous 2011-12-23 9:29

>>3
s/\*nodes/**nodes/

Name: Anonymous 2011-12-23 10:02

Sorry but I'm a Javascript coder, could you please explain? I don't understand the question.

Name: Anonymous 2011-12-23 10:06

>>5
go away FV plz

Name: Anonymous 2011-12-23 17:00

>>5

I'm combining a linked list and a multidimensional array. If you don't know what either of those are, it's time to learn a new language.

Name: Anonymous 2011-12-23 17:02

>>3

So make dimensions private and give it a constructor.

Name: Anonymous 2011-12-23 17:06

>>7
javascript programmers only know how to do cute DOM tricks and make popups

real programmers use python

Name: Anonymous 2011-12-23 17:29

(cons xlist (cons ylist zlist))

PHEW programming is hard

Name: Anonymous 2011-12-23 17:38

>>10
Yeah, tell me about it! What a bunch of whiny faggots with their inferior blub languages.

Name: Anonymous 2011-12-23 18:08

>>10
perl version: ^&*@&${*()^($)#};

Name: Anonymous 2011-12-23 19:21

>>10
faggot
>>11
huge faggot
>>12
this

Name: Anonymous 2011-12-23 22:26

>>13
butthurt, much? wolololo

Name: Anonymous 2011-12-24 1:25

>>14
fuck off and die, fagstorm

Name: Anonymous 2011-12-24 1:31

>>15
LOL! go to bed, kid. you don't know shit.

Name: Anonymous 2011-12-24 1:34

>>16
fuck off and die in a fucking chemical fire you little cunt

Name: Anonymous 2011-12-24 2:33

>>17
u mad

Name: Anonymous 2011-12-24 3:37

Fuck /b/, I'm coming here now.

Name: Anonymous 2011-12-24 6:47

Fuck /b/? Fuck me!

Name: Anonymous 2011-12-24 12:51

>>22
nice dubs bro

Name: Anonymous 2011-12-24 13:43

Thanks man.

Name: Anonymous 2011-12-24 18:04

>>21
>>22

Samefag.

Name: Anonymous 2011-12-24 18:13



Name: Anonymous 2011-12-24 19:19

>>23
nigger

Don't change these.
Name: Email:
Entire Thread Thread List