Created Problem24 class