{"problem":{"name":"024. Missed Basketball Game","description":{"content":"While you were at science olympiad, you missed your favorite basketball team's biggest game of the year. You don't know the score, but you know the number of baskets, three-pointers, and free throws m","description_type":"Markdown"},"platform":"Codeforces","limit":{"time_limit":1000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"CF10269024"},"statements":[{"statement_type":"Markdown","content":"While you were at science olympiad, you missed your favorite basketball team's biggest game of the year. You don't know the score, but you know the number of baskets, three-pointers, and free throws made by each team. Your task is to figure out which team won the game based on the given information. Recall that a three-pointer is worth 3 points, a regular basket is worth 2 points, and a free throw is worth one point. The number of baskets made includes three-pointers and two-pointers, but not free throws.\n\nThe first line of input contains two space-separated strings: the names of the two teams that played in the basketball game. The second line of input contain two space-separated integers representing the number of baskets made by each team, respectively. The third line of input contain two space-separated integers representing the number of three-pointers made by each team, respectively. The fourth line of input contain two space-separated integers representing the number of free throws made by each team, respectively.\n\nOutput a single string: the team that won the game. It is guaranteed that there is a winner, i.e. the score at the end of the game is not a tie.\n\nIn the example, Syracuse scored 95 points, and Duke scored 91 points. This game occurred on January 14, 2019.\n\n## Input\n\nThe first line of input contains two space-separated strings: the names of the two teams that played in the basketball game. The second line of input contain two space-separated integers representing the number of baskets made by each team, respectively. The third line of input contain two space-separated integers representing the number of three-pointers made by each team, respectively. The fourth line of input contain two space-separated integers representing the number of free throws made by each team, respectively.\n\n## Output\n\nOutput a single string: the team that won the game. It is guaranteed that there is a winner, i.e. the score at the end of the game is not a tie.\n\n[samples]\n\n## Note\n\nIn the example, Syracuse scored 95 points, and Duke scored 91 points. This game occurred on January 14, 2019.","is_translate":false,"language":"English"},{"statement_type":"Markdown","content":"**Definitions**  \nLet $ T_1, T_2 $ be the two team names.  \nLet $ b_1, b_2 \\in \\mathbb{Z}_{\\geq 0} $ be the number of baskets made by $ T_1 $ and $ T_2 $, respectively.  \nLet $ t_1, t_2 \\in \\mathbb{Z}_{\\geq 0} $ be the number of three-pointers made by $ T_1 $ and $ T_2 $, respectively.  \nLet $ f_1, f_2 \\in \\mathbb{Z}_{\\geq 0} $ be the number of free throws made by $ T_1 $ and $ T_2 $, respectively.  \n\n**Constraints**  \n1. $ b_i \\geq t_i $ for $ i \\in \\{1,2\\} $ (baskets include three-pointers)  \n2. All values are non-negative integers.  \n3. Final scores are unequal.  \n\n**Objective**  \nCompute the score for each team:  \n$$\nS_i = 2(b_i - t_i) + 3t_i + f_i = 2b_i + t_i + f_i \\quad \\text{for } i \\in \\{1,2\\}\n$$  \nOutput the team name with the higher score.","is_translate":false,"language":"Formal"}],"meta":{"iden":"CF10269024","tags":[],"sample_group":[],"created_at":"2026-03-03 11:00:39"}}