An exercise might ask a reader to write a computer program, that would go here in the <statement>. But you can also add a <program> element after a <statement>. Here we place no code at all, but we do say we want it to be interactive. The purpose is to make it a live coding environment for a version of your output that allows the reader to perhaps submit a solution. The <program> element is necessary so you can specify a programming language.
In interactive formats, try creating and running a Python program below. Use CodeLens to step through the program.
Similar to above, but now as a complete Python program inside an <activity>. This demonstrates the possibility to use any “project-like” block (<project>, <activity>, <exploration>, <investigation>), but not in the case when structured with <task>.
Similar to above, again, but we place the <program> element inside the <statement>, not after it as a peer. This signals that this is not a coding exercise and the program will render static, since it is explicitly labeled as not being interactive.