1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Random Linux+ Question #33

Discussion in 'Linux+' started by tripwire45, Jul 19, 2005.

  1. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    You are working with variables and have learned that there are shell variables and environment variables. You know that shell variables control the behavior of the shell itself while environment variables affect programs running outside the current shell. Some common environment variables are PATH, HOME, and USER. What command can you give that will produce a list of all the environment variables? Choose only one answer.

    1. list
    2. shell
    3. environment
    4. history
    5. export
    6. set

    Answer later.
     
    Certifications: A+ and Network+
  2. AJ

    AJ Administrator Administrator

    6,771
    102
    221
    big guess at 3
     
    Certifications: MCSE, MCSA (messaging), ITIL Foundation v3
    WIP: Looking at doing ..................
  3. nugget
    Honorary Member

    nugget Junior toady

    7,796
    71
    224
    I'll guess 3 here too.
     
    Certifications: A+ | Network+ | Security+ | MCP (270,271,272,290,620) | MCDST | MCTS:Vista
    WIP: MCSA, 70-622,680,685
  4. starfury6

    starfury6 Nibble Poster

    53
    0
    33
    I'd guess at 3 also, but it seems a bit too obvious :)
     
    Certifications: RHCT4, RHCT5
    WIP: SCSA
  5. tripwire45
    Honorary Member

    tripwire45 Zettabyte Poster

    13,493
    179
    287
    I can't believe I forgot to answer this one. Anyway, the answer is #5, "export". Type "export" at the command prompt to get a list of all environment variables. If you type "set", you'll get a list of all variables as well as their declared functions. Type "env" to get a list of all currently defined environment variables and their content.
     
    Certifications: A+ and Network+

Share This Page

Loading...