GO Lang Program to subtract two numbers
Program
package main
import "fmt"
func main(){
fmt.Println("Enter the first number")
var a int
fmt.Scanf("%d", &a)
fmt.Println("Enter the second number:");
var b int
fmt.Scanf("%d", &b)
var c = a - b
fmt.Println("Difference: ", c)
}
Output
$ go build subtract-two-numbers.go
$ ./subtract-two-numbers
Enter the first number
78
Enter the second number:
12
Difference: 66