3 ms·
Isn't it a true functional way?
by Iwan-Zotow 6y ago
Isn't it a true functional way?
- iimblack 6y agoI could definitely be wrong but I think most functional data structures aren’t fully copied. Instead, they’ll utilize something like a pointer to the data that stayed the same so only the part that changes is “copied”.
- alentist 6y agoThere are smarter ways to deal with data structures in the functional setting than copying the entire structure over and over again. See https://en.wikipedia.org/wiki/Purely_functional_data_structure https://en.wikipedia.org/wiki/Purely_functional_data_structu... and Okasaki’s book Purely Functional Data Structures.