'Exit(code
int)' method of 'os' package used to exit the application with given status
code.
Example
os.Exit(1)
App.java
package main import ( "fmt" "os" ) func main() { fmt.Println("Hello World") os.Exit(1) fmt.Println("I am not going to print") }
Output
Hello
World
exit
status 1
No comments:
Post a Comment