TenFour interview question

reading a program in VB, writing a algorithm and write a sql query.