13,145 reputation
4465
bio website nuroko.com
location United Kingdom
age 35
visits member for 3 years, 10 months
seen Aug 25 at 7:43

Hacker, game developer, CG artist and machine learning entrepreneur


Jul
21
comment Choosing language to write general library in
@Jan - But not true about binding to non-JVM systems. There are literally thousands of ways to for Java to interface to non-JVM code and systems. There is everything from JNA (native access to C libraries etc.) to socket-based solutions to REST APIs.
Jul
21
comment Choosing language to write general library in
@Jan - true that certain mobile platforms have limitations. Though mobile platforms don't really have great portability for anything (JavaScript based solutions are probably your best bet...).
Mar
24
comment Where should I declare variables used in for-loops in Java for maximum efficiency?
Probably not... though you'll need to profile it to find out. However you might want to calculate out.getWidth() and out.getHeight() once outside the loop: currently you are recomputing these on each iteration.
Jan
28
comment Returning different types from one function in a dynamically typed language
Good answer. Worth noting that the Java / statically typed equivalent is to have a function return an interface rather than a specific concrete type, with the interface representing the API / abstraction.
Oct
22
comment How would you design a programming language?
Sounds pretty much exactly like Clojure (assuming you use Mjolnir for native code generaltion on LLVM for the systems programming part - github.com/halgari/mjolnir)
Oct
21
comment I've been told that Exceptions should only be used in exceptional cases. How do I know if my case is exceptional?
"Expected" is defined by not by subjective argument or convention but by the contract of the API/function (this might be explicit, but is often just implied). Different functions / APIs / subsystems can have different expectations, e.g. for some higher level functionality a non-existing file is an expected case for it to handle (it might report this to a user via a GUI), for other lower level functions it is probably not (and hence should throw an exception). This answer seems to miss that important point....
Oct
17
comment Can a beginner in programming start learning game development?
@Dunk : maybe true - though some people already know how to create graphics (e.g. photoshop gurus) and it can be easier to experiment with something when you can see visually how it behaves. Plus tools like Slick2D (or even just Java2D/Swing) make it relatively easy to get graphics into a simple game. YMMV, I think....
Oct
4
comment What language has integrated “list insertion” as part of code *syntax*?
Haha it's a bit of a stretch to define SQL as a "programming language". As a query DSL, maybe :-)
Sep
6
comment How to significantly improve Java performance?
@maaartinus: regarding final some JITs might figure it out, others might not. It's implementation dependent (as are many performance tuning tips). Agree about the allocations - you have to benchmark this. Usually I've found it is better to eliminate allocations, but YMMV.
Aug
22
comment Is it legal to imitate how an API looks?
I believe this is on-topic as it is clearly a factor that must be considered in API design. A good answer could easily outline the general legal issues without going into the specifics of every jurisdiction.
Aug
16
comment Which programming languages are multi-platform, fast, and object-oriented with non-limiting low-level os access?
@Florian - You are seriously misinformed. Scala is 100% compiled. In fact it typically gets compiled twice: first from source to JVM bytecode, and then JIT-compiled to native code. Clojure is the same.
Jun
27
comment Should we avoid object creation in Java?
@Richard: great point - escape analysis provides some very good optimisations. You have to be careful about relying on it though: it isn't guaranteed to happen in all Java implementations and in all circumstances. So you often need to benchmark to be sure.
Jun
6
comment Will Java still be relevant in 5 years?
And FYI - you can write Java apps that work on all popular mobile platforms: libgdx.badlogicgames.com
Jun
6
comment Will Java still be relevant in 5 years?
@Erik - mobile applications are generally regarded as "Client Side"
Jun
6
comment Will Java still be relevant in 5 years?
@Erik - I'm fully aware of Node.js etc., and I still don't think it is a contender against the JVM languages (Java, Scala, Clojure) or .Net on the server side for serious applications. JavaScript is cool on the client (as I said), but the server currently has much better options. YMMV but I stand by my statements.
Jun
6
comment Aren't structured programming and object oriented programming complementary?
Hmmm Visual Basic and COM... I thought I had blanked that horror from my mind, but now it returns :-)
Jun
6
comment Aren't structured programming and object oriented programming complementary?
Most of the BASICs I knew never had virtual method dispatch? But yes, it would certainly have that kind of feel....
May
12
comment What would be a good first functional programming project?
@Giorgio: ABCL seems like it's a decent implementation of Common Lisp on the JVM. OTOH Clojure has the advantages of being designed for the JVM, incorporating a lot more "modern" innovations, and having more community momentum. I think it really comes down to whether you care about maintaining Common Lisp backwards compatibility or not.
Apr
11
comment Why aren't macros included in most modern programming languages?
@Mason - I don't think you understand the code-is-data concept. All C program source code is also data - it just happens to be expressed in text format. Lisps are the same, except they express the code in practical intermediate data structures (s-expressions) that enable it to be manipulated and transformed by macros before compilation. In both cases sending untrusted input to the compiler could be a security hole - but that's hard to do accidentally and it would be your fault for doing something stupid, not the compiler's.
Feb
4
comment Is there an established software taxonomy that's based on the type of software?
It's my own list, based on many years of experience rather than any specific research :-) . These are the things I like to know when I'm getting my head around a new software product.