Actuarial Programming

Python Haskell R and so on

Blackberry VS iPhone

leave a comment »

Recently I bought a blackberry bold for myself, and iPhone for my wife. It seems that the more I use them, the better I like iPhone. What do you think?


Written by _|_

December 24, 2009 at 5:37 pm

Posted in 1

Creating Ringtones for iPhone

leave a comment »

Came across an excellent website that enables people to convert media resources to those suitable for mobile devices, including iPhone! You may following the link here:


You need to register in order to use the website. This is because they also let you share your wallpapers and ringtones with friends. Once you upload you media, set up which portion you would like to keep and mobilespin will do the clipping and conversion for you. The resultant file can be sent to through an email link, or directly downloaded.

Written by _|_

December 24, 2009 at 5:32 pm

Posted in 1

Project Euler

leave a comment »

Stumble upon this interesting website. Interesting idea. Anyone who likes keeping some question marks in their minds must check it out!

My solution to the first question:

foldl (+) 0 [x | x<-[1..1000], x `mod` 3 == 0 || x `mod` 5 == 0]


Written by _|_

July 14, 2009 at 4:54 pm

Posted in Haskell

How do you use Haskell at work?

with 14 comments

Haskell is a beautiful language. I love Python too, but I fell in love with Haskell at first glance.

However, my problem is that I don’t know how to make use of it. Of course, I am definitely an amateur in programming, having had some programming courses in Uni, but mainly relied on internet resources. But I can figure out more ways of using Python.

So far, what I can do with haskell is to use it for office automation. Yeah, I kinda of use it the same way I used python.

I am a actuarial student, most of my stuff is in Excel; for actuarial computing, we use specialized actuairal software. How can I use Haskell in a more meaningful way?

How do you use Haskell? Especially when you are not a programmer. Thanks to whoever shares.

Written by _|_

July 13, 2009 at 3:01 pm

Posted in Haskell

Tagged with

CNNMoney : Bond report

leave a comment »

BOND REPORT: Treasurys Move Higher As Fed Buys Mortgage Bonds

For those who are concerned about the financial world. You are always welcome to share your opinion.

Written by _|_

January 6, 2009 at 1:56 am

Posted in news

Tagged with , , , ,

Monty Carlo Simulation in Haskell

with 4 comments


Just created a simple simulation of the Monty Carlo game using Haskell. Apparently the code above did not fully utilize the powerful syntax of Haskell, but it is my first product. Most importantly, it gives me the right conclusion the probability of winning by staying/switching is 33.3%/66.7%. So remember, always choose to switch!

At first it was tricky to get the types correct. And it was tricky about the indentation too. After all, it was fun and I have learnt something that I already knew in a practical way. I will feed in the details tomorrow night, if I have time ^_^.

Written by _|_

January 5, 2009 at 4:03 pm

Posted in Haskell

Haskell resources

with 3 comments

As one of my new year resolution, I started to learn a new language: Haskell. Why? It is different. It is so different from most of the languages that I knew, that at first the syntax seems so unnatural. However, after a few try-out, I cannot help thinking that I may be able to do something really serious using this brilliant language.

Here are some resources, for my own convenience, and for yours in case you are also a geeky person: center of the Haskell world

GlasGow Haskell Compiler   The de facto state of art Haskell compiler 

Real World Haskell   You can read this fantastic e-book on-line for FREE! Great for an introduction with just enough details

Haskell Wiki   We just can’t get enough of wiki’s!


Haskell’    The “research branch” of haskell language. You definitely want to check it out if you are interested in the future of Haskell.

Haskell 98 Report    The definitive resource of almost everything about the language. 

Hoogle    The Haskell API search engine which searches through GHC documentation (I might be wrong on this). (Thanks to randomdeterminism for reminding me of this important one).

Hayoo    Another API search engine which searches through HackageDB (I might be wrong on this too.)

HackageDB    Haskell package database, a gold mine where you can always find treasure and pleasure

Books on Google   Books search using google.

Yale Haskell Group     These people had involved in the development and implementation of the language from the very beginning.

Written by _|_

January 4, 2009 at 10:56 am

Posted in Haskell