YCP Logo Problem Set 5

Due: Tuesday, Dec 9th by 11:59 PM

There are several options for this problem set: do one of them.

Option 1. Implement the Sieve of Eratosthenes algorithm in Ruby, Scheme, or Prolog.

Option 2. Implement the Merge Sort algorithm in either Ruby or Scheme. It is fine to make assumptions about the type of the sorted values: for example, if you want to hard-code the implementation to sort integers, that is fine.

Option 3. Add a new data type to your YCPL interpreter. Suggestion: add support for immutable strings. Add support for literal values, and also appropriate built-in functions for working with values belonging to the new data type. Submit a short (one or two paragraph) report describing the available functions, with sample code.

Language information/reference:


This goes without saying, but do not copy or adapt a program you find on a web page, in a book, etc. The program you submit must be your work alone.


Save your work (source code, text documents, etc.) in a zip file and upload the zip file to the Marmoset server as hw5.

The Marmoset server is available using the URL: