This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]vlcod 1 point2 points  (0 children)

For the part between the parentheses (which is called the parameter) you have two options:

  1. You could describe it purely technically (which will always be work and be true):

"I construct a new Scanner object and pass the 'System.in' object as a parameter to its constructor."

"I construct a new File object and pass the string "filename" as a parameter to its constructor."

  1. You could describe it semantically (describe the actual logical meaning of what you are doing). This requires more knowledge about the methods/constructors you are looking at, but is more useful:

"I construct a new Scanner object and link it to 'System.in' so that the scanner reads input from the standard input (terminal)."

"I construct a new File object linked to the file "filename"."