Here is the practical fix. If you ask for the count straight away, the model has to recall letter facts about hidden chunks, and that recall is weak. But ask it to spell the word out first, s, t, r, a, w, b, e, r, r, y, and something changes.
When the model writes the word letter by letter, each letter becomes its own token, sitting separately on the page. The model reads its own output as it goes, so the letters are now in front of it as separate items rather than hidden inside chunks. Counting stops being a memory task and becomes a simple check of what is on the page.
Add a running tally, r one, r two, r three, and each step is tiny. Writing out intermediate steps is a well-known way to improve the accuracy of language models on multi-step problems, and this is a clean example of why it works: each step only has to handle a small piece in plain view.
This is also a likely reason many newer chatbots do better on this question: many now work through a problem step by step before they answer, which for a question like this can amount to spelling the word out, though it is not guaranteed. You are not tricking the model by asking it to do so; you are giving it letters it can actually see.