FactSet interview question

A Hackerrank medium difficulty dynamic programming problem followed by three easy SQL problems (joins and aggregations).