java.lang.ClassCastException

corejava.compare.Employee cannot be cast to java.lang.Comparable

Samebug tips0

We couldn't find tips for this exception.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web89

  • via Unknown by Unknown author,
  • via Unknown by Unknown author,
  • Stack trace

    • java.lang.ClassCastException: corejava.compare.Employee cannot be cast to java.lang.Comparable at java.util.TreeMap.put(Unknown Source) at java.util.TreeSet.add(Unknown Source) at corejava.compare.SortedSetTest.main(SortedSetTest.java:17)

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    aldrinlealaldrinleal
    2 times, last one
    Unknown visitor
    Unknown visitorOnce,
    Unknown visitor
    Unknown visitorOnce,
    Unknown visitor
    Unknown visitorOnce,