hello out there

so my professor gave me some work that i am not sure how to write. basically i need to write pseudocode and code for a couple things...

the frist one is called vertical year...