XAML is not a real programming language. It doesn’t include anything like if statements. XAML isn’t capable of making decisions.
But that doesn’t mean we can’t try.
As you may have noticed, the Clock class used the straight Hour property from DateTime, which is a 24-hour clock value. You might instead want a 12-hour clock and display the text “AM” or “PM” to indicate the morning or afternoon.
Normally you can do that by formatting the time (if the Clock class actually provided a DateTime object indicating the time) but suppose you want to be very flexible about how you display the AM and PM information—perhaps you’d prefer to display the text “in the morning” or “in the afternoon”—and you want to do it in XAML.
Here’s a new ...