Given that point C is a point on line AB and point D is the midpoint of line BC, the sum of the lengths of all line segments in the graph is 23, Connect the above problem: the length of AC and BC are both positive integers

Given that point C is a point on line AB and point D is the midpoint of line BC, the sum of the lengths of all line segments in the graph is 23, Connect the above problem: the length of AC and BC are both positive integers

A----------C-----D------B
Let AC = x, BC = y, then CD = BD = Y / 2
So: AC + AD + AB + CD + CB + DB = 23
That is: x + (x + Y / 2) + (x + y) + Y / 2 + y + Y / 2 = 23
3x+3.5y=23
6x+7y=46
Because X and y are positive integers, there are:
X=3;Y=4
The length of AC is 3