Skip to content

Latest commit

 

History

History
23 lines (14 loc) · 771 Bytes

File metadata and controls

23 lines (14 loc) · 771 Bytes

Task 2/2: Inline methods and variables

Task

In this task, you need to identify unnecessary variables and methods and inline them using the automatic Inline refactoring.

Hints

To apply the Inline refactoring, select the code you want to inline and press the &shortcut:Inline; (macOS) or Ctrl+Alt+N (Windows/Linux) shortcut.

The variable text in the main method is redundant and could be inlined.

The variables fileWriter and bufferedWriter in the getBufferedWriter method are redundant and could be inlined.

Since the getBufferedWriter method contains only one line and is used only in one method, it could also be inlined.