Query optimizer for simpledb (CS143)