adding some function and fix debug for classroom