In the plane, there are $10$ lines in general position, meaning that no two are parallel and no three are concurrent. At each intersection of two lines, we measure the smaller of the two angles formed between them. What is the maximum value of the sum of the measures of these $45$ angles?

Let's think step by step and output the final answer within \boxed{}.
user