Added main function to #14.