Code for CSIII class