Friday, January 31, 2014

Java VS JavaScript

Java VS JavaScript


Java JavaScript
language features semi-compiled semi-interpreted
object oriented
functional only from Java 8
strongly typed
classical inheritance
interpreted
object oriented
lambda or functional
loosely typed
prototypal inheritance
data types classes and primitives objects and primitives
namespace package namespace object/function namespace
meaning of object objects or class instances objects or reference types
meaning of class classes as blueprint for objects constructor functions for building classes of objects
meaning of this keyword a reference to the current object a reference to the current context
how to implement utility functions static methods for utility functions objects in the global scope for utility functions