BNSF Railway interview question

I remember three easy programming questions (similar to leetcode)