UNIX Operating System Question:

How can you get/set an environment variable from a program in UNIX?

UNIX Operating System Interview Question
UNIX Operating System Interview Question

Answer:

Getting the value of an environment variable is done by using `getenv()'. Setting the value of an environment variable is done by using `putenv()'.


Previous QuestionNext Question
List the system calls used for process management in UNIX?How can a parent and child process communicate?