Single tape Turing Machine that accepts string with at least five G's and at most three T's?
In general, whenever you try to design a machine accepting a language with this kind of &quot;finite conditions&quot;, the easiest solution is to hard-code those conditions directly into the states of your machine.
Here, you would have 24 &quot;counting&quot; states, labelled by $(g, t)$ for $0 \leq g \leq 5$ and $0 \leq t \leq 3$. Whenever you read some $G$ while already in state $(g, t)$, you move on to the corresponding state $(g+1, t)$ (and if you read a $T$, you go to $(g, t+1)$). Otherwise, you simply loop on your current state.
Now, you have to enforce your conditions: if you read a $T$ while in a state $(g, 3)$, you reject the word, and if your word end while you are in a state $(g, t)$ with $g &lt; 5$, you reject too.
Of course, there is probably some technical details to work out precisely, and there might exist some clever and trickier ideas to do this, but this method is easy to understand and can be immediately generalised to all the problems of this kind.