We live in a day and age where we tend to evolve each day on all frontiers. So is the field of programming and the languages used by programmers. While Java, C++, JavaScript, PHP, Ruby etc have been there, done that; there are plenty of other languages that are now being increasingly embraced by programmers across the globe for the sheer fact that they offer a little extra to what the majors do. Here are eight such lesser known languages creating quite the storm today.

1.Racket 6.0 - Racket 6.0 : General purpose, multi-paradigm programming language in the Lisp/Scheme family. The platform provides an implementation of the Racket language (including a sophisticated run-time system, various libraries, JIT compiler, and more) along with a development environment called DrRacket written in Racket itself. Used in a variety of contexts such as scripting, general-purpose programming, computer science education, and research.

2.OCaml 4.01 - 2.OCaml 4.01 : Main implementation of the Caml programming language that extends the core Caml language with object-oriented constructs. OCaml’s toolset includes an interactive top level interpreter, a bytecode compiler, and an optimising native code compiler. It has a large standard library that makes it useful for many of the same applications as Python or Perl, as well as robust modular and object-oriented programming constructs that make it applicable for large-scale software engineering.
3.Nimrod 0.9.2 - Nimrod 0.9.2  : Statically typed, imperative programming language that tries to give the programmer ultimate power without compromises on runtime efficiency. This means it focuses on compile-time mechanisms in all their various forms. Consists of a nice infix/indentation based syntax with a powerful (AST based, hygienic) macro system and a semantic model that supports a soft realtime GC on thread local heaps.
4. Julia 0.2.1 - Julia 0.2.1 : High-level dynamic programming language designed to address the requirements of high-performance numerical and scientific computing while also being effective for general purpose programming. Julia’s core is implemented in C and C++, its parser in Scheme, and the LLVM compiler framework is used for just-in-time generation of machine code.
5.Hack 1.0 - Hack 1.0 : Programming language for the HipHop Virtual Machine (HHVM) invented by Facebook. Hack can be seen as a new version of PHP that also runs on the HHVM, but it allows programmers to use both dynamic typing and static typing.
6.Groovy 2.2 - Groovy 2.2 : Object-oriented programming language for the Java platform that is a dynamic language with features similar to those of Python, Ruby, Perl, and Smalltalk. It can be used as a scripting language for the Java Platform, is dynamically compiled to Java Virtual Machine (JVM) bytecode, and interoperates with other Java code and libraries.
7.Egison 3.3.3 - Egison 3.3.3 : Touted as the world’s first programming language that realised non-linear pattern-matching with backtracking. It enables to represent pattern-matching against lists, multisets, sets, trees, graphs and any kind of data types, directly.
8.Clojure 1.6 - Clojure 1.6 : Dialect of the Lisp programming language, Clojure is a general-purpose programming language with an emphasis on functional programming. It runs on the Java Virtual Machine, Common Language Runtime, and JavaScript engines.

…Programmers are always advised to improve skills in C, Java, Objective C, PHP and the similar types. But the exciting part is there are few new languages which are getting introduced slowly with huge potential and entering the mainstream programming too. Some of the languages are evolved from existing languages. The newer languages are helpful towards making applications simpler for programmers.
1. D – D :
This is one of the hottest new programming languages which is used by Facebook. It’s a refreshed version of C++ and it takes its inspiration from Python, Java, Ruby, Eiffel and C#. It’s easy to write a code with D and it also doesn’t require a pre-processor. It can also tackle Unicode excellently. D is growing to expand its reach in coming years a lot with high efficiency and productivity.
2. Dart - Dart:
Dart is created by Google which is expected to become the new language for web programming.
Dart uses C like syntax and keywords and its objects are defined through classes and interfaces. Dart allows programmers to declare variables with static types, though its optional. Dart is not very usable today but it has a strong future. It’s a strong competitor for JavaScript.
3. Ceylon - Ceylon :
The creator of Ceylon programming language, Gavin King, knew it best how to create a language which is better than Java. That’s why King created Ceylon in collaboration with Red Hat. This language is said to have potential to kill Java one day. It works on the Java runtime environment only which means java has a huge role to play in Ceylon. But Ceylon offers regular syntax and developers are allowed to overcome the limitations of Java.
4. Go - Go :
It’s a programming language used for application development to system programming. It’s more similar to C and C++ than Java and C#. It has some modern features too like garbage collection, runtime reflection and more. Go language is an easy option to program with and its basic syntax is like C. The Go team aims to create a dynamic scripting language. The language is still under development and it differs from other languages a lot.
5. F# – F# :
Computer scientists are quite familiar with the concept of functional programming but programming languages like C++ and Java lack from integration of functional-style code into libraries. Here comes F# or F-sharp which is a Microsoft language and both functional as well as practical. It’s based .NET common language runtime.
6. Opa – Opa :
Web development is not a very simple thing to do. Web apps require several coding in multiple languages. HTML and JavaScript are required on the client, Java and PHP are required for server, SQL is required for database and more. Opa is not an alternative to the existing programming languages. It’s a combination of client and server frameworks.
7. Scala - Scala :
Scala is more than often compared to Java. It’s not very new as it’s there for ten years but it’s not considered one of the most essential programming languages. But Scala is said to be very productive by developers as it’s concise and more functional programming style is used in it. It also offers a potent mix of object oriented and functional programming.

9 Programming Languages For JVM.

Many programming languages have been ported to Java in the past. In fact, the JVM has not been simply native to Java for quite some time now. Not only are these other languages useful, they are often headed by big names from the technology world. Here are nine of the best of them.
Groovy – Groovy: This is an object oriented programming language that is similar to Java syntactically, but doesn’t have Java’s clutter. In fact, the compiler for groovy can easily take Java syntax, which allows developers to move seamlessly from Java to Groovy. The language also uses a type inference, which enables it to infer the type of a variable without the developer having to explicitly mention it.
JRuby – Jruby: This is a Java port of the Ruby programming language that uses the terser syntax. While this allows the developer to accomplish much more work with a single line of code. Like Groovy though, this is also an object oriented programming language. Moreover, it also has vast libraries from the Java platform, which is something Ruby doesn’t.
Jython – Jython: This scripting language, aka JPython, was amongst the first few scripting languages to be released for the JVM. It allows for dynamic compilation of Java bytecode. The language was stalled from 2005 to 2008, when the principal developer, Kim Hugunn, quit the project.
Clojure – Clojure: This is a functional programming language that is based on Lisp. In fact, based on its syntax, Clojure lies somewhere between Common Lisp and Scheme. It is big on concurrency and is a good language to use when concurrency is what you want to achieve. This program compiles to Java bytecode and is able to access the Java frameworks.
Scala – Scala: This is a multi-paradigm programming language that combines several programming philosophies. So, it is an object oriented programming language with functional capabilities and also facilitates parallel programming. It is compiled to bytecode and runs as fast as Java.
Kotlin – Kotlin: This is a statically typed general purpose language, which is compiled to the Java bytecode and to JavaScript. This language aims to create performance-critical applications, which are compiled as fast as in native Java.
Rhino – Rhino: This is an open source Java Script engine that has been written in Java. Rhino is managed by Mozilla and has the JavaScript shell for executing scripts. It is also embedded into Java applications often.
Ceylon – Ceylon: This is a general purpose statically typed imperative programming language, which is object oriented but also block structured. Ceylon is quite influenced by Java and is aimed at projects involving team-based development for large programs. It is led by Red Hat.
Fantom – Fantom: This generates bytecode at runtime for the Java Virtual Machine, JavaScript or the .Net platform from Microsoft. It has features similar to JRuby and Groovy and is an object oriented language. It integrates with Java libraries but isn’t as seamless as the other two. It has its own libraries though, which make up in part for the shortcomings.

How to write immutable classes…

IMMUTABILITY in Java.


Summary: Immutable objects have a number of properties that make working with them easier, including relaxed synchronization requirements and the freedom to share and cache object references without concern for data corruption. While immutability may not necessarily make sense for all classes, most programs have at least a few classes that would benefit from being immutable.

An immutable object is one whose externally visible state cannot change after it is instantiated. The String, Integer, and BigDecimal classes in the Java class library are examples of immutable objects — they represent a single value that cannot change over the lifetime of the object.


Benefits of immutability.


Immutable classes, when used properly, can greatly simplify programming. They can only be in one state, so as long as they are properly constructed, they can never get into an inconsistent state. You can freely share and cache references to immutable objects without having to copy or clone them; you can cache their fields or the results of their methods without worrying about the values becoming stale or inconsistent with the rest of the object’s state. Immutable classes generally make the best map keys. And they are inherently thread-safe, so you don’t have to synchronize access to them across threads.


Freedom to cache.


Because there is no danger of immutable objects changing their value, you can freely cache references to them and be confident that the reference will refer to the same value later. Similarly, because their properties cannot change, you can cache their fields and the results of their methods.
If an object is mutable, you have to exercise some care when storing a reference to it. Consider the code in Listing 1, which queues two tasks for execution by a scheduler. The intent is that the first task would start now and the second task would start in one day.


When to use immutable classes.


Immutable classes are ideal for representing values of abstract data types, such as numbers, enumerated types, or colors. The basic numeric classes in the Java class library, such as Integer, Long, and Float, are immutable, as are other standard numeric types such as BigInteger and BigDecimal. Classes for representing complex numbers or arbitrary-precision rational numbers would be good candidates for immutability. Depending on your application, even abstract types that contain many discrete values — such as vectors or matrices — might be good candidates for implementing as immutable classes.
Another good example of immutability in the Java class library is java.awt.Color. While colors are generally represented as an ordered set of numeric values in some color representation (such as RGB, HSB, or CMYK), it makes more sense to think of a color as a distinguished value in a color space, rather than an ordered set of individually addressable values, and therefore it makes sense to implement Color as an immutable class.
Should we represent objects that are containers for multiple primitive values, such as points, vectors, matrices, or RGB colors, with mutable or immutable objects? The answer is. . . it depends. How are they going to be used? Are they being used primarily to represent multi-dimensional values (like the color of a pixel), or simply as containers for a collection of related properties of some other object (like the height and width of a window)? How often are these properties going to be changed? If they are changed, do the individual component values have meaning within the application on their own?
Events are another good example of candidates for implementation with immutable classes. Events are short-lived, and are often consumed in a different thread than they were created in, so making them immutable has more advantages than disadvantages. Most AWT event classes are not implemented as being strictly immutable, but could be with small modifications. Similarly, in a system that uses some form of messaging to communicate between components, making the message objects immutable is probably sensible.


Guidelines for writing immutable classes.


Writing immutable classes is easy. A class will be immutable if all of the following are true:
All of its fields are final
The class is declared final
The this reference is not allowed to escape during construction
Any fields that contain references to mutable objects, such as arrays, collections, or mutable classes like Date:
Are private
Are never returned or otherwise exposed to callers
Are the only reference to the objects that they reference
Do not change the state of the referenced objects after construction

Classes vs. Instances of Objects

Classes of Objects & Instances of Objects.

    

Get the Flash Player to see this content.