refactor: first four section, organize cont.
This commit is contained in:
28
02-write-your-first-program/exercises/01-print-names/main.go
Normal file
28
02-write-your-first-program/exercises/01-print-names/main.go
Normal file
@@ -0,0 +1,28 @@
|
||||
// For more tutorials: https://blog.learngoprogramming.com
|
||||
//
|
||||
// Copyright © 2018 Inanc Gumus
|
||||
// Learn Go Programming Course
|
||||
// License: https://creativecommons.org/licenses/by-nc-sa/4.0/
|
||||
//
|
||||
|
||||
package main
|
||||
|
||||
// ---------------------------------------------------------
|
||||
// EXERCISE: Print names
|
||||
//
|
||||
// Print your name and your best friend's name using
|
||||
// Println twice
|
||||
//
|
||||
// EXPECTED OUTPUT
|
||||
// YourName
|
||||
// YourBestFriendName
|
||||
//
|
||||
// BONUS
|
||||
// Use `go run` first.
|
||||
// And after that use `go build` and run your program.
|
||||
// ---------------------------------------------------------
|
||||
|
||||
func main() {
|
||||
// ?
|
||||
// ?
|
||||
}
|
@@ -0,0 +1,20 @@
|
||||
// For more tutorials: https://blog.learngoprogramming.com
|
||||
//
|
||||
// Copyright © 2018 Inanc Gumus
|
||||
// Learn Go Programming Course
|
||||
// License: https://creativecommons.org/licenses/by-nc-sa/4.0/
|
||||
//
|
||||
|
||||
package main
|
||||
|
||||
import "fmt"
|
||||
|
||||
// go run main.go
|
||||
|
||||
// go build
|
||||
// ./solution
|
||||
|
||||
func main() {
|
||||
fmt.Println("Nikola")
|
||||
fmt.Println("Thomas")
|
||||
}
|
Reference in New Issue
Block a user