package main

import "fmt"

func main() {
	fmt.Println("Hello world")
}

func better() {

	price := 1.20
	grossPrice := CalculateGrossPrice(price)
	fmt.Println(grossPrice)

}

func bad() {

	price := 1.20
	taxValue := TaxValue()
	grossPrice := CalculateGrossPriceSimple(price, taxValue)

	fmt.Println(grossPrice)

}

func CalculateGrossPrice(p float64) float64 {
	return p * TaxValue()
}

func CalculateGrossPriceSimple(p, t float64) float64 {
	return p * t
}

func TaxValue() float64 {
	return 1.19
}
