A more functional sample, now via command line