All programs work for a pre-defined or a random training set