Last updated on
Final Exam Announcement
The final exam of CS-214 Software Construction will take place on Jan 30 (Thu), 08:15 - 11:15, in BC 07, BC 08, BCH 1113, CM 1110, CM 1111, CM 1112, CO 020, CO 021, CO 023, CO 260, MXF 014 and SG 0217. Please be ready in front of the rooms at 8:00AM.
You can find your assigned seat in the seat assignment chart. You can also find the seating plans of each room at the course website.
Some rooms have numbers on monitors or at the base of the computers. These are not your seat numbers. Please find your seat according to the seating plans.
A printed seating plan will be posted on the door of each room on the exam day.
Pre-exam checklist
- Bring your laptop.
- Bring your two-factor authentication device if you have one.
- Make sure you know your Gaspar password.
- Bring your own keyboard or mouse if you need them.
- Bring your camipro and a pen.
Bring your laptop.
We will use personal laptops as a backup if VDI malfunctions.
- Before coming: Make sure that your laptop is fully charged, check that Scala and VSCode work, and disable all forbidden tools (no AI assistants, no additional plugins, etc.).
- Leave your laptop in your bag, turned off, unless we explicitly ask you to use it.
Bring your two-factor authentication device if you have one.
VDI should not require your two-factor authentication code, but just to be sure, bring your mobile phone or any other device you use for that purpose. You are not allowed to use your devices unless we explicitly ask you to.
Make sure you know your Gaspar password.
You can write it on a piece of paper (you will not have access to your password manager). Do not change your password less than 24 hours before the exam.
Bring your own keyboard or mouse if you need them.
You may bring a keyboard and mouse to the final if you do not like the QWERTZ (Swiss layout) keyboards that are already in the rooms, but:
- Note that you can only change the keyboard layout after logging in, i.e., you need to type your username and password in the QWERTZ layout.
- Make sure that the keyboard or mouse works ahead of time.
- Make sure your equipment is quiet: no mechanical keyboards, no loud keyboards, no loud clicky mice, no bright lights, etc.
You may bring passive (non powered) ear protection such as earplugs (but make sure that you can still hear announcements!).
Exam Protocol
Format
The final exam will consist of multiple exercise sets and mini-labs, similar to the exercises and labs that you solved during the semester. Each exercise set or mini-lab will be submitted separately on Moodle. Each exercise set or mini-lab will be worth a number of points indicated in the corresponding writeup.
You must use Scala to complete the exam. Any Scala constructs are permitted.
Environment
You will have access to a physical computer provided by EPFL running a locked-down virtual desktop instance (a virtual machine), with the following software installed (version numbers may change slightly):
Software | Version |
---|---|
Java | 17 |
Scala | 3.5.0 |
SBT | 1.10.1 |
Coursier | 2.1.18 |
VSCode | 1.95.3 |
VSCode plugin: Scala (Metals) | |
VSCode plugin: Scala Syntax (Official) |
You are only allowed to use the following resources during the exam:
- Websites:
- Our Moodle site
- Our course website, which contains the Scala documentation.
- Documents: course materials, labs, and exercises, but only those that are found on the CS214 Moodle site or on our website.
- Applications: browser, terminal, and the tools you need for coding.
You may not bring additional documents (no printed, handwritten, or electronic materials), except for a piece of paper with your Gaspar password if needed.
Setup
-
Doors will open at the latest 10 minutes before the beginning of the exam. We may have to start late if any room runs into difficulties.
-
Find your seat.
-
Log into your VM using the machine’s QWERTZ keyboard.
You can only change the keyboard layout after logging in, i.e., you need to type your username and password in the QWERTZ (Swiss) layout.
After you change the keyboard layout, the VDI login screen will use the updated keyboard layout.
There is no “view password” button in the VDI login screen. If you are really not sure about what you have typed, you can type your password in the username field where you can see, then cut and paste it into the password field.
-
Plug in your keyboard if you brought one, and configure the keyboard layout.
-
Open our course website (cs-214.epfl.ch) in firefox and click “Final exam announcement” to open this page if you need.
-
Mute your computer:
We have updated this part. Please use the VDI menu instead of the Ubuntu sound settings to mute your computer.
Hover your mouse on the bottom-right corner of your screen to trigger the VDI menu. Click the sound icon and set the volume to zero.
-
Open a terminal, but do not type anything.
-
Wait for permission to unzip
final.zip
and start the exam.
Exam instructions
Instructions and code scaffolds will be provided as a ZIP file named final.zip
in your home directory.
-
Unzip
final.zip
.Do not use the graphical file browser to open the zip and do not open
index.html
directly from the zip. Instead, use the command line. Otherwise, pages extracted from the zip will not load properly.- Open the terminal.
- Run the command
cd
(to go to your home directory~
). - Run the command
unzip final.zip
. This will create afinal
directory.
-
Open the home page of the exam.
Run the command
firefox final/index.html
to open the exam’s home page. -
Start working on the exam.
For each exercise set or mini-lab:
-
The scaffold code will be at
final/code/<name>/
. -
The instruction will be at
final/instructions/<name>/index.html
. You can open the instruction by clicking from the exam’s home page. -
To work on an exercise set or a mini-lab, open the directory
final/code/<name>
in VSCode. You can use the following command to do so:code ~/final/code/<name>/
Do NOT open the
final/
directory directly in VSCode, otherwise Metals and worksheets will not work properly. -
Let Metals import the original exercise set or mini-lab before you start coding and changing the files.
-
When you open the
final/code/<name>/
in the VSCode for the first time, Metals will show a popup window:Click “Import build”.
-
If there is no popup window at 30 seconds, you can click the Metals button on the left panel, then click “Import build” in the Metals menu:
-
Wait for Metals to import the build. The import is not yet finished if, on the VSCode bottom-left corner, you can see the build server (bloop or sbt) is still running or Metals is indexing:
Wait until import is complete to start coding.
-
-
To run the tests of an exercise set or a mini-lab, run
sbt test
under the directoryfinal/code/<name>
.Do not run
sbt
directly infinal/
, otherwisesbt test
will not work. -
It’s OK to create new files and directories under
final/
. Make sure all your files are underfinal/
. -
Auto-save is not enabled. Save your work often.
You need to save your code to get the updated Metals information (errors, typing information, etc).
How to enable auto-save in VSCode
You enable auto-save in the File menu:
You can see a tick in front of “Auto Save” when it is enabled.
-
Do not delete any of the pre-created folders and files (~/.sbt, config files, etc). If you do, we will help you restore, but it will take time, you may lose data, and you will not get extra time to compensate.
-
-
Submit your solution via Moodle.
You will submit your solutions through Moodle, like you did for labs during the semester. Each exercise set and mini-lab will be a separate assignment on Moodle.
Typing
moodle epfl
on the firefox address bar will not work, as it attempts to make a Google search formoodle epfl
but you do not have internet access.Instead, you can type the full url
moodle.epfl.ch
, or click the submission link from the exercise set or mini-lab instruction page.- Make sure to run tests locally on your machine with
sbt test
before submitting. - Submit your solutions as soon as possible for each question. Do not wait until the end of the exam to submit all exercise sets and mini-labs at once.
- In most cases, only your last submission will count: make sure not to submit broken code.
- You will not be able to submit a new version of a solution until the last submission is graded. We will reopen submissions at the very end of the exam for one last chance to submit if needed.
- Make sure to run tests locally on your machine with
-
At the end of the exam, you will have five minutes to submit your solutions one last time. Note the automatic grader can take time when everyone submits together, so you may not see its output for that last submission.
-
After the last five-minutes submission window, stop using the computer and log out to close your session.
- At the end of the exam, we will ask everyone to stop using the computer. Make sure to submit your work before that.
- Except for unforeseen circumstances, code not submitted to Moodle will not be graded.
- Make sure to use the log out menu option to close your session:
Grading
In almost all cases, your grade will be determined by automatic tests. Just like during the semester:
- There are no hidden tests.
- We reserve the right to confirm your final grade by checking your understanding of your code through a brief oral examination.
Exam length
We have designed the final exam to take more than 3 hours to complete in full. This is on purpose, and it is accounted for in grading. We do not expect you to solve all questions.
Tips
- Be strategic: skim through all problems and start with the ones you’re most comfortable with.
- Don’t waste time: some tests are harder than others (in some case, we have even indicated that in the exam.)
- Go deep: reading and understanding a problem takes time, so doing just the first few questions of each problem may not pay off. It’s often better to invest in a few problems than to do a small bit of every problem.
- Use the tests: We will give you all tests: use them for debugging.
No cheating!
-
No internet access, no coding AIs, no inside or outside help, no circumventing tests (no asInstanceOf, no hardcoding, …), no heliographs. This list is not exhaustive. Check the allowed materials in the environment section above.
-
Do not attempt to bypass the restrictions (you may only access course materials, labs, exercises, and debriefs during the exam), etc. We have lots of current and former EPFL students on staff — we know the tricks. This will be treated as a cheating attempt.
-
All tests will be provided (there are no secret tests), but: do not hardcode non-trivial cases! We will review solutions, and solutions that pass exactly the provided tests but nothing else will be rejected (and treated as a cheating attempt).
This is OK:
def fact(n: Int): Int = if n == 0 then 1 else n * fact(n-1)
This is NOT OK:
def fact(n: Int): Int = n match case 0 => 1 case 6 => 120 case 12 => 479001600
-
We know about Moodle chat. It will be turned off during the final (and all activity will be logged anyway.) Nice try. Seriously: don’t cheat.