|
Re: What is your most prefered programming language?
Favorite language: C++
Java is high up there, but I think they oversimplified it. I like the added OOP, but why they removed operator overloading is beyond me (anyone know why?). When I write games in C++, I have a Vector class and a Matrix class and I can do nice, simple statements like:
position += velocity * deltaT + .5 * (sumOfForces / mass) * deltaT * deltaT;
velocity += (sumOfForces / mass) * deltaT;
But in Java, you get ugly statements that force you to create temporary variables to store things as you go.
That's why I'm starting to look at C# a lot. It's a lot like Java except they brought back all the good stuff from C++ that Java left out, and then some.
I also used to love PHP, but now I don't like it that much. The lack of strong variable types makes it easy to write programs, but impossible to go back and read what you wrote a week later. Perl is the same.
C is pretty fun. I like working with pointers and making sure you keep track of everything, especially on embedded systems. Writing stuff for the Palm in C really gives you an appreciation for memory management. If you leak one byte of memory or go beyond your allocated memory by one byte, you get a fatal error (or at least it seems that way).
asm is pretty interesting to use, but only in small doses. I'd like to see someone write their entire robot code in asm (it doesn't count if you just disassemble the C code).
|