apache/incubator-flink — pull request #78 by mariemayadi (2014-07-24 14:20:57+00:00)
Title: Add Pi approximation Java example

Hadoop and Spark have a Pi approximation basic example (similarly to WordCount, PageRank ...), so for homogeneity it is worth having it in Flink as well.

Note:
The final result, count, which in this case is the approximation of Pi had to be assigned the type DataSet instead of just Double (due to Flink limitation)
So aside from executing a summation, the reduce (at the collector level) also does a little math operation, which could have not been applied on type DataSet.