Skip to main content

Tutorial 4

info

As mentioned in class, this tutorial will not be discussed in class. However, we are leaving this page here in case you want to give it a try yourself!

Tutorial Questions

  1. In this question, we will attempt to architect software. Let us design an in-memory Redis clone!

    Basically, Redis is a key-value store. There is a command-line interface in which you can write, for example, SET name "Herbert". If we then do GET name, it should return the value "Herbert".

    For this exercise, we shall implement a Redis CLI in the form of an iOS application. For now, the commands that we support are:

    • SET k "v": sets the key k to the value v

    • GET k: gets the value of the key k

    • FLUSHALL: clears the store

    1. Let us design the object that backs this store. How will it be like? What is the underlying data structure used? What will be its APIs?
    2. How do we parse whatever input the user passes in? What objects will handle that? What will be its APIs?
    3. How will the user interface look like? How do we design them? What will be its APIs?
    4. How do we extend this implementation? For example, what should we do if we want this Redis clone to support having arrays as its values?

There might be not enough time to discuss all of the following, so we shall just discuss those that interests you.

  1. Implement a text editor in the form of an iOS application.

  2. Implement a vertical scrolling rhythm game. For an example, see e.g. this video.

  3. Implement a clone of the Atari Breakout game. For an example of the gameplay, see e.g. this video.

  4. Implement a ride-sharing app like Gojek or Grab.

  5. Implement a Microsoft Paint clone in the form of an iOS application.

If you want, we can also try designing projects that people in the past have built for their CS3217/CS3216 final projects: