First commit with a very simple first function

This commit is contained in:
2025-10-01 23:18:27 +01:00
commit 02e77f41bd
3 changed files with 15 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
# UnitConv
Basic package to hold reusable unit conversion operations.
Used mainly for my simracing projects so that's the scope of the unit conversions I need
here.
+3
View File
@@ -0,0 +1,3 @@
module github.com/ESilva15/unitconv
go 1.25.1
+7
View File
@@ -0,0 +1,7 @@
// Package unitconv provides useful unit conversions
package unitconv
// MsToKph converts a float64 representing m/s to an int representing km/h
func MsToKph(v float32) int {
return int(3.6 * v)
}