Dynamic Programming Languages

Level

Grundläggande nivå - First cycle course

Requirements

60 hp Computer and Systems Sciences with at least 15 hp programming

Short description

This course examines the philosophy behind dynamic languages. We do so in the context of several different dynamic and scripting languages, e.g Python and Ruby, two proven dynamic languages with different strengths and weaknesses. We use dynamic languages as the full-blown programming languages they are, and we will also examine the use of dynamic languages for integration and as tools for metaprogramming, especially for implementation of domain-specific languages. We will also look at other interesting languages like io and Clojure, for interacting with e.g., Java programs and the Java API.

Aim

Having successfully completed the course with grade E or higher, a student should be able to:

Syllabus

Dynamic languages, sometimes called ’scripting languages’, are high-level, dynamically typed programming languages, often developed in the open-source community and prone to change more rapidly than proprietary-owned languages such as Java and C#. Dynamic languages are flexible and powerful; recent studies suggest that programs written in dynamic languages are about five times shorter than their static equivalents. This means shorter development time and thus cost, and produces programs that are easier to read, change and maintain.

Dynamic languages have been called the ’unsung hero of the world-wide web’. Many well-known systems, like the Amazon shopping-site or Google are built on top of dynamic languages. Dynamic languages have also found widespread use as tools for intergrating different systems and components. Dynamic languages are also used to script larger systems or as a high-level interface to a lower-level language. The nature of dynamic languages also facilitate metaprogramming, where the language is used to manipulate the language itself. This is superb for the implementation of domain-specific languages. Domain-specific languages raise the level of abstraction even further than objects and allows the programmer to express the program in terms of the domain. An excellent example of the use of metaprogramming is in the implementation of Ruby on Rails, an MVC framework for building internet applications. Rails allows automatic generation of interfaces straight from the code and provides high-level variable declarations such as "belongs_to" and "has_many", all coded in Ruby, and accessible from within the programming language itself.

The popularity of dynamic languages is increasing. The old maxim that static compile-time checks are necessary to build secure software is questioned time and time again by acknowledged people, programmers and academics alike, and the dynamic philosophy maps very well with the popular agile methods like XP and test-first development.

In this course, we will examine the philosophy behind dynamic languages. We do so in the context of of several different dynamic and scripting languages, e.g Python and Ruby, two proven dynamic languages with different strengths and weaknesses. As well as using dynamic languages as the full-blown programming languages they are, we will examine the use of dynamic languages for integration and as tools for metaprogramming, especially for implementation of domain-specific languages. We will also look at prototype-based languages like IO and high-level languages like Groovy, for interacting with e.g., Java programs and the Java API.

DYPL (last edited 2015-11-23 12:01:29 by cabe3634@su.se)