title: Go from end of string to "/" and assign to var C++
body: <p>Here is my filepath <code>my/example/path</code> I need to capture <code>/path</code> and assign it to a variable. I don't know if this involves regex, what is the best way to do this in C++?</p>