When you solve a problem you’ve asked for help for, please update your post so people don’t waste time trying to find out what’s wrong
Edit:
May as well post it anyway, in case anyone in the future makes the same mistake
Consider the testcase:
1
500000000 250000000 1000000000