Programming Languages in the 2000s Judith Bishop University of Pretoria, South Africa
Position of the course Third year, optional, popular students Students know Java and C++ well They have some C# (web oriented) No other languages Compilers is an optional course too
Aims of the course COS333 appreciate the rich history familiar with paradigms skills in new languages appreciate principles exposed to the new trends
Previous course pre-2004 Progression of imperative languages -variables -types -procedures -concurrency etc Other paradigms -object-oriented -functional -logical -scripting -high performance History
Timeline 2001C# 1.0 2002 2003 Spec# 1.0 2004Java 1.5, Comega 2005C# 2.0, Spec# 2006Java 6, C# 3.0, LINQ
Advances in Auto boxing and unboxing 2.Properties 3.Foreach and switch on objects 4.Indexers 5.Enumerated types with IO 6.Events and delegates 7.Generics
Advances in 2006 The LINQ extensions to the.NET Framework provide Comega’s language- integrated query, set, and transform operations to C# and Visual Basic IEnumerable expr = from s in names where s.Length == 5 orderby s select s.ToUpper();
Current course Imperativelanguages Other paradigms Object-oriented New paradigmsHistory 15,16, notes 1,2 11,12, notes 5,6,7,8, 9,10,14,13 notes
Student Assessment Set up website to teach one language from another Include only five features Write two examples (one given, one free) Students look forward to this assignment See examples at
Sample Oops Question The difference between what can be accomplished in generics in C++, Java and C# is largely based on their implementation. Describe the three approaches and indicate especially how each handles the case of generic instantiation of primitive types. Comment on the potential efficiency (in space and time) of the different approaches.