Skip to content

Commit

Permalink
Update main.go
Browse files Browse the repository at this point in the history
  • Loading branch information
miguelpragier authored Oct 15, 2021
1 parent 68b4fac commit 80851bc
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ import (
// It means that this "globalVariable" below is global within main package.
var globalVariable bool // this global-scoped variable is initialized with "false" value


/* Functions Order */
// You can sort the functions according your favorite logic.
// I like to put init() ( when present ) as first function and main() as last.
// For me it's important to see the function writen before/above the function that calls it.

// init function executes before main() function, and is designed to
func init() {
globalVariable = true
Expand Down

0 comments on commit 80851bc

Please sign in to comment.