JavaScript : Some Basic Facts

Objects in JavaScript There are three basic datatypes in JS :  Number , Boolean and String typeof  is a function which can be used to identify the underlying object type [code] var x = new String("Hello"); alert (typeof(x)); // will return Object alert( x instanceof String); // will return true [/code]   [code] var x = new Boolean(true); alert (typeof(x)); // will return Object alert( x instanceof Boolean); // will return true [/code]   [code] var x = new Number(5); alert (typeof(x));... more →
Posted in: Programming

Java vs Ruby Class – A Syntax Comparison

The objective of this article is to compare the structure of  a class in Java and Ruby. I believe this will help Java or Ruby developers to compare one another. As an example let us consider a simple Employee class with three attributes – first name, last name , email and city. Java Version [code] public class Employee { private String firstName; private String lastName; private String email; private String city; public Employee(String firstName, String lastName, String email, String... more →
Posted in: Programming

Why I don’t like programming in Ruby / RoR

Confession Let me start with a confession. I am not a Ruby or Ruby on Rails (RoR) developer. My knowledge on this topic is purely based on self study and observation of various RoR projects Why I am writing this series I am software engineer and I always love to learn and understand about new technologies, programming languages and frameworks. I came across Ruby and RoR in 2007 and I made an attempt to study Ruby. I read that it is a cool language and it is very easy to learn. I made an attempt... more →
Posted in: Programming