Example programs in scala