Blue letters in the beginning of a line is the day the announcement was made
Please reload the page frequently as it will be updated during the course.
(2026/04/26) Plan for the third week (April 27th)
pl02_recursion and
pl03_typedef(2026/04/26)
binheap and tttree were
added after the last lecture; they are beyond “learn-a-new-language”
level and far more challenging than problems you have seen; I encourage
you to tackle one of them there are bonus points associated with it(2026/04/26)For any non-trivial program, you should master a skill to examine a program to get it right. Here are a few basic things to remember.
ocaml
command) and Jupyter (jupyter) to run functions
interactively and see their outputs; this way you can examine if each
function is doing what it is supposed to dogo build -gcflags="all=-N -l" program.go
dlv exec ./program
ocamlc -o program -g program.ml
ocamldebug ./program
gdbrustc -C opt-level=0 -C debuginfo=2 program.rs
gdb ./program(2026/04/20) Plan for the second week (April 20th)
pl02_recursionpl02_recursionpl03_tyepdefpl02_recursion and pl03_typedef will
become assignments you need to submit; due: around May 2nd; you will be
required to solve one or two problems in each topic in >= 2
languages; detailed spec will come later(2026/04/13) No class today, due to entrance ceremony.
(2026/04/13) I made errata of problems below
(2026/04/03) Home page for AY2026 is out. Welcome!
(2026/04/03) We use PC during the class. Bring your device.
(2026/04/03) We are going to use Jupyter environment for your work. See How to access Jupyter environment
(2026/04/03) You use UTokyo Account (10-digits@utac.u-tokyo.ac.jp) to sign in; you will be assigned a separate user name on the Jupyter server. Your user name has been distributed via UTOL (see How to access Jupyter environment above).
(2026/04/03) Accounts have been set up for the following people, so please make sure you will be included.
(2026/04/03) Plan for the first day (April 7th)
pl00_intro to practice
submitting your work, in Jupyter and UTOL (Assignment 1 :
pl00_intro)pl01_basics; no need to submit itIn this course, we provide a dedicated Jupyter environment along with an AI tutor that you can interact with.
You can use this tutor to ask questions or get feedback on your answers.
If you are wondering what you can legitimately ask AI — especially when it could solve many of the exercises perfectly — that is exactly the kind of concern a serious learner should have.
I will address this both as a general principle and as a more specific policy in this course.
To learn effectively, I recommend the following when using AI:
A good rule of thumb is to interact with AI in small steps, reading and digesting each response as you go.
Another way to put it is:
The worst way to use AI for learning is to ask AI to do what you are asked to do.
For a simple example, suppose you are asked to write a function
that takes a, b, and c and computes cos (a + b + c),
but you do not yet know the language you are using.
You should ask questions such as:
instead of:
In this small example the difference may not matter much, but I hope you get the idea.
Interestingly, this is almost the opposite of what is often called “advanced” use of AI for work productivity:
In learning, however, the situation is fundamentally different:
If you do not know how to decompose a problem, you may ask AI for help with that (e.g., “I have no clue. What basics do I need to learn to approach this problem?”).
To be clear:
The point is that learning efficiently is fundamentally different from simply getting things done efficiently; learning is about making lasting changes to your brain.
[OK] Ask general questions to help you solve a problem (e.g., how to write functions in Go)
[OK] Ask for hints about how to decompose a problem into steps
[OK] Ask what is wrong with your answer (e.g., debugging errors)
[OK] Ask for feedback on your answer
[OK] In larger problems later in the course, ask AI to generate small, well-defined components
[NG] In small problems in the early part of the course, ask AI to generate the full answer
[NG] Use auto-completion tools (e.g., GitHub Copilot) that effectively write the code for you
[NG] Ask AI to generate a substantial part of a project in a single prompt
There will always be borderline cases, however. When unsure, get back to the principles or consult me.
In this course, we provide a dedicated Jupyter environment along with an AI tutor that you can interact with.
Within this environment, the following information will be recorded:
These data help us understand where students struggle, how they approach problem solving, and what kinds of questions they ask
Our goal is to use this information to improve teaching and to conduct research on learning and education
The collected data may be used for:
When used for research purposes, personally identifiable information will be removed or anonymized as appropriate.
No information that could identify an individual will be published or publicly released.
The data will be handled in accordance with applicable regulations and university policies.
Use of data that identifies an individual is strictly limited to pedagogical purposes within this course, for the benefit of that student, such as providing feedback to them.
In particular, we do not use what you asked AI, let alone how it responded, for grading or cheat detection. You can choose not to provide data; and we are fully aware that serious cheater could use other AIs.
Your participation is entirely voluntary (opt-in)
If you choose not to consent:
You may also withdraw your consent later by sending this form again
If you are willing to contribute your data, please indicate your consent using this form at any time you feel comfortable:
We appreciate your cooperation in helping us improve learning for future students.
variables/gaussian_density problem, the problem states that
the function takes “x, μ, and σ” (suggesting this order of
parameters), but the test code assumes it takes μ, σ, and x in this order; I found a few of
you suffering from assertion error caused by this. Apologies
m(_ _)mFor each language, I recommend a few documents
Tutorial — good to get started, good to sequentially read while commuting
Cheetsheet — good to remember syntax after you master the concept
Reference/Spec — good to know detailed spec when necessary