3 ms·
Yes, the real problem with this implementation is the data structure they use. But is `next == null` a special case? ogod what do we do?!
by klyrs 8y ago
Yes, the real problem with this implementation is the data structure they use. But is `next == null` a special case? ogod what do we do?!
- banku_brougham 8y agoThis is interesting. Is it possible to implement a linked list while eliminating the end of the list ‘edge case’, in the fashion of the parent article?
- pure-awesome 8y agoCreate a "sentinel" node which represents null and also points to itself, perhaps?