Skip to main content

Timeline for answer to V10's Operator Forms - what are they good for? by m_goldberg

Current License: CC BY-SA 3.0

Post Revisions

2 events
when toggle format what by license comment
Aug 7, 2014 at 2:21 comment added Ronald Monson In a previous comment it was mentioned how operator forms can be used to refactor code as part of improving readability but also efficiency. As illustrated by other answers, operator forms can replace occurrences of Function (introduced to deal with nested #&'s) suggesting a refactoring in the code of this answer and in particular a dropping of one of the Table's iterators. The snippet Table[youngest[Select[#age == x &] /* CountsBy[#survived &] /* ({#[True], #[False]} &)]//Normal,{x,Range@cutoff}] is equivalent, perhaps of comparable readability but certainly improved efficiency-wise.
Aug 3, 2014 at 14:17 history answered m_goldberg CC BY-SA 3.0