Interprete cd and ls commands Flashcards

1
Q

what will this do?

cd

A

go to home directory for the currently logged in user.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

what will this do?

cd /

A

go to root directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

what will this do?

cd ..

A

go up one directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

what will this do?

cd ../..

A

go up two directories

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

what will this do?

cd ~

A

go tho user’s home directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

what will this do?

ls /

A

show files and directories in root directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

what will this do?

ls /*ot

A

Show any files or directories that end in ot

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

what will this do?

cd /
ls ./

A

go to root directory and print a list of all it’s contents

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

what will this do?

mkdir ~/cli-tmp

A

make a directory named cli-tmp inside the home directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

what will this do?

cd users

A

go into the users directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

what will this do?

cd -

A

returns to last directory path you were in

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

what will this do?

ls ..

A

list files in the parent directory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

List 3 different ways to go to home directory

A

cd ~
cd $HOME
cd

How well did you know this?
1
Not at all
2
3
4
5
Perfectly