1 // $G $F.go && $L $F.$A && ./$A.out
3 // Copyright 2009 The Go Authors. All rights reserved.
4 // Use of this source code is governed by a BSD-style
5 // license that can be found in the LICENSE file.
12 pi = /* the usual */ 3.14159265358979323
28 func (p *Point) Initialize(x, y int) *Point {
33 func (p *Point) Distance() int {
34 return p.x*p.x + p.y*p.y
45 func min(x, y int) int {
52 func swap(x, y int) (u, v int) {
58 func control_structs() {
59 var p *Point = new(Point).Initialize(2, 3)
67 for j := 0; j < i; j++ {
81 case i == 0, i == 1, i == j: