Bird
0
0

Which of the following is the correct syntax to change to a directory named projects inside the current directory?

easy📝 Syntax Q3 of 15
Linux CLI - Navigating the File System
Which of the following is the correct syntax to change to a directory named projects inside the current directory?
Acd /projects
Bcd ~projects
Ccd ..projects
Dcd projects
Step-by-Step Solution
Solution:
  1. Step 1: Understand relative vs absolute paths

    Without a leading slash, the path is relative to the current directory.
  2. Step 2: Analyze each option

    cd projects changes to the projects folder inside current directory; cd /projects looks in root; others are invalid.
  3. Final Answer:

    cd projects -> Option D
  4. Quick Check:

    Relative path cd projects = C [OK]
Quick Trick: No slash means relative path; use cd foldername for subfolders [OK]
Common Mistakes:
MISTAKES
  • Using /projects looks in root directory
  • Adding invalid characters like ~ or .. before folder name

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Linux CLI Quizzes