Questions tagged [branching]

This tag can be appropriately applied to questions on teaching and using `if` and `switch` statements along with similar constructs in other languages.

Filter by
Sorted by
Tagged with
2 votes
1 answer
103 views

What are some good conditional branching excercise scenarios?

I want to get my students to exercise the conditional-branching mind-muscle. [edit: and I need it to be fun/playful] I will ask them to read pseudo-code, then represent as a branching sketch[^1]. And ...
Vladimir's user avatar
  • 123
4 votes
5 answers
203 views

Uses of selection in programming (if, switch etc)

I am an experienced programmer that has just started teaching. I am struggling to see how to introduce selection to my programming classes. None of the examples that I have seen so far are good. I am ...
ctrl-alt-delor's user avatar
4 votes
2 answers
404 views

Motivating examples for switch/case in Java

Students first see switch/case as a second syntax for if/...
Ben I.'s user avatar
  • 32.9k