Finished program 3.