Putting the Fun in Functional - AndroidListener Chicago, October 2015

Putting the Fun in Functional - AndroidListener Chicago, October 2015

My talk on being a crazy person who decided to rebuild map, filter, and reduce functions in Java 7 so I could better understand what the hell they're doing.

And also on sandwiches.

Code be here: https://github.com/designatednerd/FunInFunctional-Android

C4861b1dfdf3bbb21faec4a1acdf183d?s=128

Ellen Shapiro

October 22, 2015
Tweet

Transcript

  1. Putting the Fun* in Functional * - may depend on

    your definition of fun by Ellen Shapiro AndroidListener Chicago, October 2015
  2. The Big 3 Functional Methods map filter reduce

  3. None
  4. What do these methods DO? -map: Apply the same function

    to everything in this collection
  5. What do these methods DO? -map: Apply the same function

    to everything in this collection -filter: Return the things in this collection passing a test function
  6. What do these methods DO? -map: Apply the same function

    to everything in this collection -filter: Return the things in this collection passing a test function -reduce: Combine the things in this collection with a starting value, and a function that adds things to a starting value.
  7. None
  8. None
  9. None
  10. Demo Time!

  11. Don't Do What Donny Don't Did (At least if you

    want to be functional)
  12. Side effects!

  13. None
  14. None
  15. Question Time!

  16. Links! — Sample Code: https://github.com/designatednerd/ FunInFunctional-Android

  17. Photo Credits! — Sandwich photo by Molly Elliot: https:// www.flickr.com/photos/mollyelliott/4576766142

    — Square peg in a round hole photo by Yoel Ben- Avraham: https://www.flickr.com/photos/epublicist/ 3546059144 — Pills by Thirteen of Clubs: https://www.flickr.com/ photos/thirteenofclubs/