Problem in Campus Drive

Hello guys,
I was trying to solve Campus Drive but am constantly getting SIGSEGV. Here are my submissions. It would be great if anyone can point out where I am going wrong!

Thanks in advance and sorry for my fuzzy codes!