[Welcome to Sensei's Library!]

StartingPoints
ReferenceSection
About


Referenced by
ComputerGo

Homepages
BenShoemaker

 

Computer Go Language Question
    Keywords: Question

So you want to write a computer go program?

If you're a programmer, you probably know C/C++.

But is this the best language for prototyping/experimenting with a go program?

Here are some languages to consider: (I'll add "Go" specific info if/when I try them out)

  • Common Lisp: Strong tradition in AI programming
  • Java: GUI, Platform Independance
  • OCaml: Fast, Flexible, Multi-Paradigm (functional, imperitive, oo)
  • Perl: Easy to Learn, Flexible
  • Prolog: Rapid Prototyping
  • Python: Easy to Learn, Flexible
  • Ruby: Similiar to Perl and Python but better OO

Gorobei: Common Lisp gets my vote: fast, rich, interactive, and flexible. I'm no Lisp expert, so my attempt to write a Go Program is also an attempt to learn CL. Because I'm a novice Go player, my Go programs have been full of false assumptions and poor models of aspects of the game: CL's multi-dispatch object system has helped greatly in letting me reshuffle things without redesigning class hierarchies, etc. I've written over 500,000 lines of C/C++, so it is my first language, but I'm finding CL more expressive and less constraining.


MrKoala: As a CaML expert, I recommend OCaml. Not only because I like this language, but also because it is strongly typed. As far as I know, CL is an untyped language. I'm also trying as a personal research subject to use CaML syntax for generating optimized code in other languages.

(note from NeonSquare?: CL is not an untyped language. It is a strongly typed language too. The difference is that ML is statically typed and CL dynamically typed. For optimization CL supports optional weak static typing too.)


Jan: I'm writing my Go program in Haskell (a lazy, functional language). No real reason for the language choice except that I like it a lot and that it allows coding at a high level of abstraction. And besides, the name HaGo can also stand for Hand of God :-)


WilliamNewman: CL is nearly in a class by itself, both in good ways and in bad ways. Two good ways are its "macros" (actually general code-writing code) of unparallelled power, and its integration of interpreter and debugger with user-defined printing operations (so you can view your data in high level form, even inside debugger operations like backtraces). One bad way is the way that code-writing code makes life difficult for useful tools like "make". OCaml is extremely impressive in lots of ways, and full of powerful ideas (e.g. functors), but when I tried it (late 2001) I was very frustrated by its difficulties in expressing mutually recursive data structures (e.g. an object representing a square of the Go board, where one of the slots of the object is a hash table, and the hash table values include collections of squares on the Go board; or see [ext] here for more info). I think in a language for working with Go, you want that kind of thing to be easier than it is in C++, not harder!



This is a copy of the living page "Computer Go Language Question" at Sensei's Library.
(C) the Authors, published under the OpenContent License V1.0.