Winning cb scholarship

only half of the test cases run why this happens can you plz check my code

please use long long instead of int