• Post Reply Bookmark Topic Watch Topic
  • New Topic

abstract int ''something'' ;  RSS feed

 
ekte spiriopoulos
Ranch Hand
Posts: 217
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am confused this part of code is right or wrong?abstract int getDoorCount(); they told me is wrong.Only private,public,protected we can use.Your opinion?
 
Henry Wong
author
Sheriff
Posts: 23295
125
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The code looks valid to me. Who told you it was wrong? And what's wrong with it?


And BTW, from your other topic...

http://www.coderanch.com/t/666829/java/java/abstract-field

Thank you for not calling those methods as "fields" in this topic. It might be pedantic, but when you mess up official terminology, it makes it hard to communicate.

Henry
 
Campbell Ritchie
Marshal
Posts: 56599
172
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Henry Wong wrote:The code looks valid to me. . . .
If somebody tells you that code which compiles without warning is “wrong”, it is for them to explain what is wrong. you should ask for that explanation, and then post it here so we can all understand what is happening.

And how did the exam go?
 
ekte spiriopoulos
Ranch Hand
Posts: 217
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Campbell Ritchie wrote:
Henry Wong wrote:The code looks valid to me. . . .
If somebody tells you that code which compiles without warning is “wrong”, it is for them to explain what is wrong. You should ask for that explanation, and then post it here so we can all understand what is happening.

And how did the exam go?
My friend (I hope not annoying you call you )because you have helped me and other help me here enough i thank you all guys.Yes i will ask him The exam..i would say i am not good enough to overcome to it.Now September i give it again Also,i have to learn c++ and i don't know anything :P I give my effort to "learn " as much as i could Java .Now i should start c++ :P .I think until September i will be able to write Java and c++ good
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!