More inputs and outputs for RGAME

Hi I would like to know if there is more examples of inputs and outputs for RGAME problem. To be honest, I don’t understand very well why the result of 1 2 1 is 14. I was thinking in something like this:
1*
1 2* -> 2
2* 1 -> 2
1 2* -> 2
1 2 1*-> 2
2 1 1*-> 1
2* 1 -> 2
1* 2 1 -> 2
1* 1 2 -> 1
total = 14
Where number* is the number that I read from the input, but I’m not sure about it. I hope you can help me.