Fwd: Re: [Shootout-list] Ray tracer developments

Jon Harrop jon@ffconsultancy.com
Sat, 30 Apr 2005 20:27:04 +0100


On Saturday 30 April 2005 14:10, Isaac Gouy wrote:
> LOC is a poor measure of how long the code is, let alone anything else.
> Most folk notice that the original OCaml programs compress more onto
> one line than they otherwise might.

There are much better reasons (like higher-order functions) than OCaml 
squeezes more into each line.

Check out the new page I just uploaded, comparing the C++ and OCaml 
implementations of my ray tracer:

  http://www.ffconsultancy.com/free/ray_tracer/comparison.html

In this case, the variant type is vastly more succinct than a class hierarchy.

> I don't understand how LOC could be a surrogate for complexity.

I think it is a case of doing the best we can. LOC is quantitative, complexity 
isn't. I can think of several other measures of complexity but none of them 
are as realistic or quantifiable as LOC.

-- 
Dr Jon D Harrop, Flying Frog Consultancy Ltd.
Objective CAML for Scientists
http://www.ffconsultancy.com/products/ocaml_for_scientists