Challenge - 5 Problems
Terminal vs GUI Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate1:30remaining
What is the output of this command?
You run the command
ls -l /tmp in a terminal. What does this command do?Linux CLI
ls -l /tmp
Attempts:
2 left
💡 Hint
Think about what the
ls command does and what the -l option adds.✗ Incorrect
The
ls command lists directory contents. The -l option shows detailed info like permissions, owner, size, and modification date. It does not open GUI windows or delete files.🧠 Conceptual
intermediate1:30remaining
Why might a user prefer a terminal over a GUI?
Which of the following is a common reason users choose to use a terminal instead of a graphical user interface (GUI)?
Attempts:
2 left
💡 Hint
Think about what typing commands can do compared to clicking icons.
✗ Incorrect
Terminals let users type commands and automate tasks with scripts, which can be faster and more precise than clicking in a GUI. GUIs provide visual elements like icons and drag-and-drop, but terminals do not.
🔧 Debug
advanced2:00remaining
Why does this GUI automation script fail?
This script is supposed to open a text editor and type 'Hello' automatically using GUI automation tools. Why does it fail?
Linux CLI
import pyautogui pyautogui.write('Hello') pyautogui.press('enter')
Attempts:
2 left
💡 Hint
Think about what must happen before typing can work in a GUI.
✗ Incorrect
The script tries to type immediately, but if the text editor is not open and focused, the typing goes nowhere. The 'write' function is correct, 'enter' is valid, and root permissions are not needed for typing.
🚀 Application
advanced1:30remaining
How to switch from GUI to terminal in Linux?
You are using a Linux desktop with a GUI. Which key combination lets you switch to a terminal console (TTY)?
Attempts:
2 left
💡 Hint
Think about function keys and how Linux manages multiple consoles.
✗ Incorrect
Ctrl + Alt + F3 switches to the third terminal console (TTY). Ctrl + Shift + Esc opens task manager in some systems, Alt + Tab switches windows, and Ctrl + C interrupts commands.
🧠 Conceptual
expert2:00remaining
What is a key advantage of scripting in terminal over GUI automation?
Which advantage best explains why scripting in a terminal is often preferred over GUI automation for repetitive tasks?
Attempts:
2 left
💡 Hint
Consider what can break GUI automation scripts easily.
✗ Incorrect
Terminal scripts use commands that do not rely on screen layout or resolution, making them more stable. GUI automation depends on screen elements and can break if the interface changes. Terminal scripting requires command knowledge, and GUI scripts can fail or be slower.