Lambda the Ultimate

inactiveTopic Notes on "Algebra of Programming"
started 2/27/2003; 11:55:43 AM - last post 2/27/2003; 11:55:43 AM
Ehud Lamm - Notes on "Algebra of Programming"  blueArrow
2/27/2003; 11:55:43 AM (reads: 2097, responses: 0)
Notes on "Algebra of Programming"
The "banana-split" law in action.

The notes show how this theorem can be used to reason about two algorithms for calculating the average of a list of numbers, and prove their equivalence: A straightforward inefficient solution (sum/len) and more careful implementation that only traverses the list once.

Posted to functional by Ehud Lamm on 2/27/03; 12:00:18 PM