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
How do you create a reference page in apa format with all websites?
Gre4nikov [31]
Use Cite This For Me's APA citation generator to create a reference page in APA format with all websites.
6 0
3 years ago
Explain the difference between undecidable problems and unreasonable time algorithms. Be specific.
ddd [48]

One for which no algorithm can ever be written to find the solution is an unsolvable problem. An undecidable problem is one for which no algorithm can ever be written that will always provide any input value with a correct true/false option.

6 0
2 years ago
Hen using presentation software, what do you do when you "compose a slide"?
Tamiku [17]

Answer:

using Microsoft power point .

Explanation:

Start by opening a "Blank presentation" in PowerPoint. ...

Select the "Title Slide" option. ...

Type in your title and subtitle. ...

Select a background for the entire presentation. ...

Add new slides. ...

Set the transitions for your slides. ...

Add some more pizzazz to your presentation with animation!

7 0
3 years ago
How much space should be allotted to park your vehicle parallel to the curb?
alexandr1967 [171]

there is no definite answer. so long as you are not touching another vehicle or in the road.

6 0
3 years ago
Suppose you want to view a document that has several headings. what view would you use?
bija089 [108]
Um i think outline. :)
5 0
3 years ago
Other questions:
  • Which of the following should you avoid when designing your Print resume?
    11·1 answer
  • The invention of the transistor was important to the development of computers because
    14·1 answer
  • the technique of blocking some parts of a photograph to emphasize (or draw attention to) another part of the same photograph is
    8·1 answer
  • Which of the following allows the transmission of voice and often video communication over the internet?
    12·1 answer
  • The camera still is bad even with the new iPhone xr and especially in low light it is even worst because you can see the pixels
    15·1 answer
  • User defined blocks of code can be created in
    13·1 answer
  • Generally speaking, what is a “best practice"?
    13·1 answer
  • What is this....... Iam booking train to patna. ​
    13·2 answers
  • A user calls the help desk reporting that a laptop with Linux freezes on startup and displays kernel panic. What could cause thi
    12·1 answer
  • Network connections implemented with the use of a cable modem take advantage of?
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!