3 ms·
If you look at the design of java (the fundamental basics at least), it makes sense as lets take C++, but design it again from scratch with the problems fixed:
by rkangel 8y ago
If you look at the design of java (the fundamental basics at least), it makes sense as lets take C++, but design it again from scratch with the problems fixed:
* Syntax is fine, keep it
* Mixed C heritage creates confusion, lets double down on OO and make everything an object
* Mistakes in managing heap memory (allocating, freeing, ownership changes) are the cause of lots of bugs, so we'll do that automatically (GC)
* Overrunning arrays is bad so we'll prevent that
* Exceptions are great, but sometimes it's unexpected that a function is going to throw one - put it in the type signature
* Having to compile for lots of different targets is a pain, so lets provide one common abstraction layer so that our code will run anywhere (multiple desktop OS's, Web, embedded)