(Re-)Assignments

A variable is only really a variable when it changes, right? As mentioned earlier, variables "point to values". And we can change what we point to over time (in Solidity, as long as their general data type string|uint|bool|... remains the same).

If we look into the constructor of our Marketplace contract, we see the following expressions:

// We set the owner to the caller of this function,// which was Matt & John (LarvaLabs) themselvesowner = msg.sender;// We set the total supply to ten thousand punkstotalSupply = 10000;// We set the punks to assign initial owners to the total xsupply (10,000)punksRemainingToAssign = totalSupply;// We set the name to the string `CRYPTOPUNKS` and the symbol to `Ͼ`name = "CRYPTOPUNKS";symbol = "Ͼ";

All these assignments above either initially set or change the pointer of our variables to a new value.

Check out line 17 and 95:

// Line 17bool public allPunksAssigned = false;function allInitialOwnersAssigned() {  // Line 95  allPunksAssigned = true;}

We initially instantiate allPunksAssigned with false, and change it to true in the allIninitialOwnersAssigned() function.