Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Rules Roundup nitpicking

 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I just checked out the Rules Roundup for the first time today. Way cool! Thanks JavaRanch!
I do have a couple of nitpicks to share:

question #106
Is this legal?
public static void main(String [ ] fred)

In what context?

question #121
Does a final member variable have to be initialized at the time its declared?

"its" should be "it's"
 
Marilyn de Queiroz
Sheriff
Posts: 9066
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
question #106
Is this legal?

public static void main( String[ ] fred )

In what context?


I don't understand your question about the question. Is it legal or is it not legal to declare the main() method this way? What does context have to do with it?

"its" should be "it's"

You're absolutely correct!
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It is obvious that this is a method header. Perhaps this determination is the purpose of the question.
It would seem to me, though, that this is also the header for the main method in a Java application that could serve as the main entry point for the JVM to that application.
So, does "Is this legal?" mean:
"Is this legal as a method header?"
or
"Is this legal as the main entry point to an application?" (or similar wording)
Sure, in both cases the answer is the same. That's why I'm just calling it nitpicking.
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And since you're paying attention to this post, another nitpick:

Question # 328
TRUE or FALSE: in a try/catch construct, the catch blocks may be written in any order and the most narrow/specific catch argument is chosen at

Perhaps my display was cutting the question short and there were more words to follow - but it just looks like a small grammatical error to me.
As a side note: I'd be glad to run through the questions in the rules roundup and make any small grammatical/spelling changes - if you trusted me
 
Marilyn de Queiroz
Sheriff
Posts: 9066
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Dirk Schreckmann:
It would seem to me, though, that this is also the header for the main method in a Java application that could serve as the main entry point for the JVM to that application.
So, does "Is this legal?" mean:
"Is this legal as a method header?"
or
"Is this legal as the main entry point to an application?" (or similar wording)
Sure, in both cases the answer is the same.

Yep. The answer is the same. And "fred" is just as legal as "args".
 
Marilyn de Queiroz
Sheriff
Posts: 9066
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Dirk Schreckmann:
in a try/catch construct, the catch blocks may be written in any order and the most narrow/specific catch argument is chosen at

Perhaps my display was cutting the question short and there were more words to follow - but it just looks like a small grammatical error to me.

"in a try/catch construct, the catch blocks may be written in any order and the most narrow/specific catch argument is chosen at runtime."

Must've been your display.
 
Marilyn de Queiroz
Sheriff
Posts: 9066
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Dirk Schreckmann:
I'd be glad to run through the questions in the rules roundup and make any small grammatical/spelling changes - if you trusted me

That's not my decision to make.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic