If you like me are learning Scala you might after a bit of coding realize that even if it is possible to write java-like code in Scala – and by using some of the nice features of Scala it will actually be more fun than writing normal Java code. It will quite often look a bit ugly and not feel that natural.

That is because it is not the Scala-way of doing it.

I’m still trying to understand the Scala-way of thinking but it’s not something you pick up over night. I’m taking baby steps and hopefully making some progress every day.

Two articles I found yesterday helped me understand how to assign immutable variables from if-statements and how Scala loves recursion:

“Kotaku has posted their liveblog of the QuakeCon 2010 keynote, with some big announcements by game developer and Slashdot regular John Carmack. Highlights include a video of the id Tech 5 engine (aka Rage) running on the iPhone 4G at 60fps, with claims that it also runs on the iPhone 3GS.

Another hilarious quote from John Carmack was

“The game would have been more enjoyable if people could actually see it.” – Carmack on Doom 3

“Facebook said the results of using HipHop have been dramatic. CPU usage on Facebook servers has dropped by an average of 50 percent as the HipHop PHP engine reduced the load on Facebook’s infrastructure.”

“This is not an extension to PHP — this is pretty different,” Recordon said. “Right now, the process is once you build and compile HipHop, it comes with a tool that will go through the transformation process and output the binary, and that’s what you actually use to run it.”

And the fact that they’ve removed Apache and uses an own web server. I start to wonder if what they do is actually take the PHP source code and compile it to get one binary that is both the web server and the application in one.

PHP is an interpreted script language so what normally happens is that PHP takes the source file and reads it line by line as it’s executing it. If they’ve bypassed this step completely by pre-compiling the script file into machine code that would explain the reduced CPU usage.

This video shows “Snow Stack”, a 3D CSS Visual Effects demo built with HTML, CSS Effects and JavaScript in the latest WebKit nightly on Mac OS X Leopard and Snow Leopard. You can try this out yourself by reading the details on www.satine.org.

Wow! This is mad impressive! And if it’s true that the graphics card is doing most of the work and the CPU is hardly loaded at all, it is borderline crazy!