command-line-basics Flashcards

1
Q

What is a CLI?

A

Stands for command-line interface. It accepts text input to execute operating system functions.

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

What is a GUI?

A

Stands for graphical user interface. It is a form of user interface that allows users to interact with electronic devices through graphical icons and audio indicators instead of text-based UIs, typed command, labels, or text navigation

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

Give at least one use case for each of the commands listed in this exercise.
man
cat
ls
pwd
echo
touch
mkdir
mv
rm
cp

A

man: an interface to the online reference manuals; system manual pager
Cat: concatenate files and print on the standard output
Ls: list information about the files (the current directory by default)
Pwd: print the full filename of the current working directory
Echo: display a line of text; echo the string(s) to standard output
Touch: change file timestamps; update the access and modification times of each file to the current time; creates file if it does not exist
Mkdir: make directories if they do not already exist
Mv: move or rename files
Rm: remove files or directories
Cp: copy files and directories

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

What are the three virtues of a great programmer?

A
  1. Laziness: The quality that makes you go to great effort to reduce overall energy expenditure. It makes you write labor-saving programs that other people will find useful and document what you wrote so you don’t have to answer so many questions about it.
  2. Impatience: The anger you feel when the computer is being lazy. This makes you write programs that don’t just react to your needs, but actually anticipate them. Or at least pretend to.
  3. Hubris: The quality that makes you write (and maintain) programs that other people won’t want to say bad things about.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly