Linux Practice Test
Linux+ Linux+ Bash Scripting and Automation 2
Which construct is used to iterate over each line of a file in a Bash script?
Select your answer
A
for line in $(cat file.txt)
B
while IFS= read -r line < file.txt
C
while IFS= read -r line; do ... done < file.txt
D
foreach line in file.txt
Hint
✨ Remove Ads & Unlock Every Exam
— From $1.49
🃏 LINUX Flashcards — Study This Quiz as Flip Cards →
📚 Want to go deeper? Read the Full LINUX Study Guide →