Skip to main content

Posts

Showing posts from September, 2013

Object Oriented JavaScript - Part I

What is JavaScript? JavaScript is a prototype based scripting language with dynamic typing and has first-class functions. Previously it is mostly used in web and mobile browser application development. These days it is used for performing server side operation. The best example is Node JS. What is static and dynamic languages? In static languages, the process of verifying & enforcing constraints of type and identifying the behaviour of the code can happens at compile time itself. Some of the static languages are Java, C#, etc., In dynamic languages the above process is can happens only at run time. This feature will helps to include new code, modifying type systems, and extending objects at run time. What is first-class functions? In many languages like Java and C# have some options for defining class. For an example, this is my Person class in Java. class Person { String firstName; String lastName; } In JavaScript we don't have any keyword like