main = print . take 10 $ scanl1 (+) [0..]
Standard input is empty
[0,1,3,6,10,15,21,28,36,45]
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!