blob: 95aef9831c03a96009e01d6fd9449b727f9ff4cb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
package main
import (
"./forces"
"./structs"
"fmt"
)
func main() {
// the slice starsSlice stores the star structures
starsSlice := []structs.Star{
{structs.Coord{X: 100, Y: 100}, structs.Force{0, 0}, 1000},
{structs.Coord{X: 200, Y: 300}, structs.Force{0, 0}, 1000},
}
fmt.Println(starsSlice)
fmt.Println(forces.ForceActing(starsSlice[0], starsSlice[1]))
}
|