ex4&5 finished. Added template.