CSC302 2011S Programming Languages

Assignment 5: Scala

Assigned: Monday, 21 February 2011
Due: 11:00 p.m., Thursday, 24 February 2011

This assignment is also available in PDF.

Summary: In this assignment, you will explore Scala as compared to two languages you already know: Scheme and Java.

Purposes: To give you more experience with Scala. To help you think about the design of different languages.

Expected Time: Three to four hours.

Collaboration: I would prefer that you work on this assignment in groups of two or three. You may also work on this assignment alone or in groups of up to size four. You may consult with anyone you wish on this assignment (including other classmates), provided you cite your consultants.

Submitting: Upload a tarball to Pioneerweb.

Warning: So that this assignment is a learning experience for everyone, I may spend class time publicly critiquing your work.

Assignment

0. Determine how immutable lists are implemented in Scala and give a short explanation of the implementation.

1. Write a short programming problem and the obvious solutions in Scala and Scheme for which it is clear that Scala is better suited to solving the problem.

2. Write a short programming problem and the obvious solutions in Scala and Scheme for which it is clear that Scheme is better suited to solving the problem.

3. Write a short programming problem and the obvious solutions in Scala and Java for which it is clear that Scala is better suited to solving the problem.

4. Write a short programming problem and the obvious solutions in Scala and Java for which it is clear that Java is better suited to solving the problem.

Important Evaluation Criteria

I will look at the standard C criteria: Is your code correct? Is your code concise? (This second attribute is particularly appropriate in Ruby.) Is your code appropriately commented? Have you used any particularly clever techniques. How comely is your code?

Submitting Your Homework

Create a directory for this assignment of the form hw05.names. Within that directory, create subdirectories for each part of the assignment (e.g., part0, part1). Each subdirectory should contain:

Make a gzipped tarball of the assignment directory. (If you don't know how to do that, let me know.) Upload it via the Assignment 5 link on Pioneerweb.

 

History

Monday, 21 February 2011 [Samuel A. Rebelsky]

 

Disclaimer: I usually create these pages on the fly, which means that I rarely proofread them and they may contain bad grammar and incorrect details. It also means that I tend to update them regularly (see the history for more details). Feel free to contact me with any suggestions for changes.

This document was generated by Siteweaver on Mon Feb 21 07:14:40 2011.
The source to the document was last modified on Mon Feb 21 07:14:36 2011.
This document may be found at http://www.cs.grinnell.edu/~rebelsky/Courses/CSC302/2011S/Assignments/assignment.05.html.

You may wish to validate this document's HTML ; Valid CSS! ; Creative Commons License

Samuel A. Rebelsky, rebelsky@grinnell.edu