• Post Reply Bookmark Topic Watch Topic
  • New Topic

[question]"int cannot be dereferenced" [line17]  RSS feed

 
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

The question require calcInt%2 compare with 0(that is 'even') and return true to identifier.
above code is my attempt,however it prompt "int cannot be dereferenced".
what is mean about?what else i need to do?

Sincerely
 
author
Sheriff
Posts: 23295
125
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what is mean about?what else i need to do?



The error message is saying.... "even" is an int -- it is not an object. Hence, it doesn't have an equals() method.

Henry
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!