Code for the MPP