double linked list Nodes python
Ok, the only way I can really learn this stuff is to see how it works. So next in my class is making a double linked list.... So I need to know how the nodes work in order to manipulate them. I spent A LOT of the day making diagrams until one made sense. Then I spent hours playing with creating nodes until I figured out how I needed to set them up. Here's my pretty. Not as creative as the other ones, but I'll do something better next time. The thing I figured out is this.... If I say x = "yellow".... an address is created in my python compiler to store that variable x. I can change x as many times as I want, to --almost-- anything I want, and the address remains the same. So when your modifing the nodes, their address stays the same, so link is still just the address to them. You can change the actual contents of that address --almost-- to anything you want to. ...