Hi, welcome to CS142! This course provides comprehensive training for designing, analyzing, implementing, and reasoning efficient algorithms. Designing efficient algorithms is one of the most useful skills in computer science, but only taking basic algorithm courses is usually insufficient for developing this skill.

CS 142 Algorithm engineering will cover this training in two aspects. First, the students will receive a list of problems with real-world background, and solve them using the algorithmic knowledge from previous courses. Skills including problem formalization, algorithm design, optimization and implementation, and debugging will be exercised. Second, we will cover useful knowledge for parallelism, I/O-efficiency, and other system and architecture features to accelerate algorithms. At the end of the course, students will be equipped with knowledge in designing efficient algorithms in practice.

To graduate students: yes, you can take CS 142 to fulfil your electives requirement (12 units for PhD and 32 units for master’s). You can see the list of courses here.

We will use CampusWire for online discussions, and GradeScope to submit homework assignments. The invitation will be sent to your emails at the beginning of the quarter. The course announcements will be sent via Canvas or CampusWire, so please make sure you enable email notifications from these systems.

You will likely find this course to be difficult. There are several reasons why. First, Computer Science and Engineering are challenging disciplines requiring extensive time to master, and algorithm is the core of it. Second, the material covered in the course, combines both theory (analysis of algorithms) and practice (implementing them), and thus require you to have solid background in both math and programming. Third, this course will require generating your own algorithms in addition to just memorizing and understanding existing algorithms. If you don’t know programming, then there will also be the additional overhead of learning coding, and you should start learning it immediately. There are many online resources for doing so.

It is thus important for you to mentally prepare yourself for a difficult course. If you do your work, we are confident that you will finish this class with a satisfactory grade, and will one day (if not immediately) find what you learned in this course useful in your career (and fun, hopefully).

Please make sure you understand the policy of the course, especially about Academic Integrity.

Prerequisites: CS 141 with “B-” or better.

You should still attend the course and do the homework on time, even if you cannot register before the quarter. If you need more information, you should send an email to the instructor. Remember this is a 10-week course, so if you miss several lectures and homeworks, it is less likely that you can make up.


  • Yan Gu

    - Email: ygu [at] cs.ucr.edu
    - Lectures: Mon & Wed 6:30 – 7:50 PM
    - Classroom: Student Success Center 316


  • Zheqi Shen and Zijin Wan

    - Email: available on Campuswire

A Quick Note about emailing course staffs

Please refrain from unnecessarily emailing course staff because the emails are likely to be ignored (although usually unintentionally), or you may get a response very late if that person is busy at that time. We recommend you to post on CampusWire that is visible only to TAs and instructors, and thus anyone seeing the post can reply. You could (and should) email instructors privately in cases that require privacy.


  • Tue, 11:00 - 11:50 AM


You can add the this to your Google Calendar if you want (by clicking the little “+” bottom right). All the lectures and assignment deadlines are included in this calendar.


Introduction to Algorithms (CLRS).
Third Edition. Cormen, Leiserson, Rivest, and Stein. MIT Press.
[UCR Library Link]