Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

instanceOf & the instanceof.

 
thejaka samarakoon
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is the difference with What is the difference with instanceOf & the instanceof.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Only one of them is a reserved Java keyword. Can you guess which one ?
 
Deepak Bala
Bartender
Posts: 6663
5
Firefox Browser Linux MyEclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thejaka samarakoon wrote:What is the difference with What is the difference with instanceOf & the instanceof.


Coincidentally, there is a similarity at the beginning of your question.

Try to compile a sample program with those words in order to understand the difference
 
Sahil Kapoor
Ranch Hand
Posts: 316
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Unfortunately method should be instanceOf but it is instanceof

Another method is mkDir() which is actually mkdir().

 
Mahmoud Hossam
Ranch Hand
Posts: 74
Linux Netbeans IDE Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sahil Kapoor wrote:Unfortunately method should be instanceOf but it is instanceof

Another method is mkDir() which is actually mkdir().



instanceof is an operator,not a method

also,mkdir was named after the linux of the same name,which does the exact same job as this method,creating directories
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic