I actually thought of that when I wrote my comment.  But still, notice that (1) the instructions take as their input registers that point to the data (ie. a char pointer), not some machine-level idea of a &quot;string&quot;, and (2) the cost of these instructions is still O(n), even though you don&#x27;t have to write the loop manually.