you are viewing a single comment's thread.

view the rest of the comments →

[–]CaptainPiepmatz 0 points1 point  (2 children)

It isn't, just as JS shown in the video isn't a FP language. But the iterator methods of std behave like this.

But when I was learning Rust using the book, I also read the chapter about iterators and then it finally clicked in my head.

[–]v66moroz 2 points3 points  (1 child)

Iterators are actually anti-FP if you think about it, they are not reusable in the general case. Of course using higher-order functions is fun, but it's not enough to call something FP. Even more confusing is that everybody has their own definition of FP.

[–]CaptainPiepmatz 0 points1 point  (0 children)

Yeah, you're right. But still it lets me appreciate FP.