You are viewing a single comment's thread. Return to all comments →
--My c# solution
public static void bonAppetit(List<int> bill, int k, int b) { bill.RemoveAt(k); int actualCost = bill.Sum()/2; if(b == actualCost){ Console.WriteLine("Bon Appetit"); } else{ Console.WriteLine(b - actualCost); } }
Seems like cookies are disabled on this browser, please enable them to open this website
Bill Division
You are viewing a single comment's thread. Return to all comments →
--My c# solution