That's not too difficult, I'm doing it on the one I'm setting up.. go to where it prints the subject in showflat and showthreaded, then add something like this..
( Post#: $Number / re: $Parent )
I believe both variables are pulled in with the query, but I can't remember... I didn't give you line numbers in the code to go to because my code is so far off now it probably wouldn't even come close to matching. Make sure to look for it in both top and side post formats... Also, I have 5.0.8, so I can't vouch for anything higher than that.