[Home]
[Edit this page]
[Recent Changes]
[Special Pages]
[Help]
CppGetenv
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
CppGetenv
(C++) std::getenv
Standard function to get the environments of the OS.int main () { const std::string path = std::getenv("PATH"); std::cout << "The current path is:\n" << path << std::endl; }
- include <cstdlib>
- include <iostream>
- include <string>
[Edit this page] [Page history] [What links here] [Discuss this topic] [Printer Friendly]
