1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
4vir4ik [10]
3 years ago
9

Which method can be used to write data to a text file opened with the BufferedWriter object outfile?

Computers and Technology
1 answer:
maksim [4K]3 years ago
7 0

Answer:

Option (d) outfile.write();

Explanation:

As the object created for the class BufferedWriter is outfile, outfile.write is the correct syntax for writing in a text file. Here, write is the method used for writing into a text file. The data present is written in the textfile. Here, the text file is opened before writing the text into the file. Option (d) is correct.

Option (a) outfile.newLine(); is used to separate the lines. This is used to break the existing lines into smaller lines. This can also be used to start a new line. Here, newLine() is the method.So, option (a) is not suitable.

Option (b) outfile.existLine(); This is not a valid syntax as there is no method called existLine() in the class BufferedWriter. So, this is a wrong option.

Option (c) Write(outfile); This is not a valid syntax for writing in a text file. This is a wrong option.

You might be interested in
Meaning of sperm count
yulyashka [42]

a measure of the number of spermatozoa per ejaculation or per measured amount of semen, used as an indication of a man's fertility.


5 0
3 years ago
Read 2 more answers
What happens when a user updates a record after a developer creates a Workflow Rule declaratively that updates a field on an obj
Sindrei [870]

Answer:

d. The trigger is fired more than once.

Explanation:

What would happen in this situation is that the  trigger would be fired more than once. This is because the trigger will be fired when the user updates the record. It will also be fired when the process builder is run.

If the trigger fires more than once, this can be problematic for the developer. Therefore, it is better if the trigger fires just once, as this is the time when the present changes can be placed.

5 0
3 years ago
A computer memory that acts as the main storage available to user for programs and data
Gelneren [198K]

Answer:

Primary storage. Primary storage (also known as main memory, internal memory, or prime memory), often referred to simply as memory, is the only one directly accessible to the CPU.

3 0
2 years ago
If you have created a document that contains a table that is 10 inches wide and 4 inches high, you will want to print the docume
Papessa [141]
True you will want to print the document in Landscape orientation
6 0
3 years ago
Read 2 more answers
Computer viruses often spread by means of what?
lozanna [386]
Email attachments hope this helps
8 0
3 years ago
Read 2 more answers
Other questions:
  • What feature did the 32X add to the Sega Genesis?
    13·1 answer
  • Rebooting the computer is a good troubleshooting technique.<br><br> True<br> False
    6·2 answers
  • Assume that a 5 element array of type string named boroughs has been declared and initialized. Write the code necessary to switc
    5·1 answer
  • The signature area in a cover letter includes the sender's first and last name, followed by his/her job title (if applicable). *
    13·1 answer
  • What is the location used by users to configure delegate access on their own mailboxes? Backstage view &gt; Account Settings Bac
    12·1 answer
  • Which of the following would most likely be the target audience for a product
    7·2 answers
  • Which of these is NOT a usual result of having friends at work?
    8·1 answer
  • Two forms of compression are lossy and lossless. State giving reasons which
    8·1 answer
  • Write code that outputs variable numCats. End with a newline.
    6·1 answer
  • Choose the missing term.
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!