How can i fix this equals on primitive type(int)

equals() is used for Objects (StringInteger, etc…)

For primitives like intbooleanchar etc, you have to use ==

Leave a Comment