Separated program to 3 distinct parts