Last Two Lines
Print the last two lines of log.txt, in the order they have in the file.
Example 1
log.txt
INFO job 1 WARN disk 3 INFO job 2 ERROR mail 7
prints
INFO job 2 ERROR mail 7
Constraints
log.txthas 2 to 25 lines
Write it in your browser, against the clock. The model script, with a note on each command it uses, comes after.
More Bash problems
- Lines With ERRORBeginner
- One After the OtherBeginner
- Only the Text FilesBeginner
- Sort the NamesBeginner
- Colour to ColorEasy
- Each Line OnceEasy
- Everything but DEBUGEasy
- Find the Python FilesEasy