Start at the end. If you start from the beginning, you will have a mess!
1/2 of the remainder = 4 + 3, that is she had 14 and gave 10 to her best friend
then
2/3 of the remainder = 14 + 4, that is she had 27 and gave 13 to her sister
then
2/3 of the original amount = 27 + 1 that is she had originally 42 pens and gave 15 to her brother