title: traversing C string: get the last word of a string
body: <p>how would you get the last word of a string, starting from the '\0' newline character to the rightmost space? For example, I could have something like this where str could be assigned a string:</p>
  
  <pre><code>char str[80];
  str = "my cat is yellow";
  </code></pre>
  
  <p>How would I get yellow?</p>