In the "I'm amused" department, I just discovered that Google has it's own programming language. While not surprising, it was interesting.
Seems some of my 'haven't used it in over a decade' C knowledge is still useful. lol
FYI.
[h=2]Examples[/h] The following is a Hello world program in Go:
Go's automatic semicolon insertion feature requires that opening braces not be placed on their own lines, and this is thus the preferred brace style; the examples shown comply with this style.[SUP][17][/SUP]
Example illustrating how to write a program like the Unix echo command in Go:[SUP][18][/SUP]
More info
http://golang.org/
http://www.eweek.com/c/a/Applicatio...About-Googles-Go-Programming-Language-859839/
http://en.wikipedia.org/wiki/Go_(programming_language)
Seems some of my 'haven't used it in over a decade' C knowledge is still useful. lol
FYI.
[h=2]Examples[/h] The following is a Hello world program in Go:
Code:
package main
import "fmt"
func main() {
fmt.Println("Hello, World")
}
Example illustrating how to write a program like the Unix echo command in Go:[SUP][18][/SUP]
Code:
package main
import (
"os"
"flag" // command line option parser
)
var omitNewline = flag.Bool("n", false, "don't print final newline")
const (
Space = " "
Newline = "\n"
)
func main() {
flag.Parse() // Scans the arg list and sets up flags
var s string
for i := 0; i < flag.NArg(); i++ {
if i > 0 {
s += Space
}
s += flag.Arg(i)
}
if !*omitNewline {
s += Newline
}
os.Stdout.WriteString(s)
}
More info
http://golang.org/
http://www.eweek.com/c/a/Applicatio...About-Googles-Go-Programming-Language-859839/
http://en.wikipedia.org/wiki/Go_(programming_language)