modify class frequency.java