AI-powered
podcast player
Listen to all your favourite podcasts with AI-powered features
The Relationship Between a Scan and a Fold
The way APL and Q view it, is that a scan is kind of a fold with extra information. But in this other view, it's like the scan and the fold both tell you different information about what you get when you're traversing the array. So if I understood that correctly, your exclusive scan is similar to the C++ one where it takes an initial value and gives you back an elements.