twitter cortex 电面

面的twitter cortex的ml infra.
给一个2d matrix, query the sum of a sub matrix within the given matirx. note: there will be a lot of queries.