Mode:
Duration:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
package main
import (
"fmt"
"os"
)
func main() {
os.Setenv("APP_PORT", "8080")
os.Setenv("APP_ENV", "development")
port := os.Getenv("APP_PORT")
env := os.Getenv("APP_ENV")
fmt.Println("Environment:", env)
fmt.Println("Port:", port)
}Coding works best on desktop or with an external keyboard.