Thank you so much!
Could you please explain how the code works? I'm not very good at this string manipulating stuff... I do know how to use pointers but not very well...