Did P6 and P7, looked at P8

not sure yet how to do P8 in java