IT 244: Introduction to Linux/Unix
Answers to Class 20 Ungraded Quiz

  1. What command would you run to see the last 20 commands you ran at the command line?
    history 20
  2. What is the PATHNAME of the file that, by default, stores the commands you have run in a file so that they will be remembered for the next time you log in?
    ~/.bash_history
  3. What command would you use to edit the last command to run, change it and run it again?
    fc
  4. What is the name of the library of procedures that allows you to edit the command line?
    the Readline library
  5. Name the three things that can be completed at the command line by hitting Tab.
    pathnames, commands, shell variables
  6. What do you call a shortcut that is used to run a command?
    an alias
  7. What would you write at the command line to create the alias ghdir which changed directory to MY home directory?
    alias ghdir='cd ~ghoffman'
  8. Can you write a function on a SINGLE command line?
    yes if every command is followed by a ;, including the last
  9. Can aliases be made global?
    no
  10. Can functions be made global?
    no