In order to solve this you are going to need to make an equation to solve it. One way is that we can make the amount of replacement cartridges into the variable of x. You need to equal all of it to 865 by doing this:
865 = 60 + 23x
Subtract each side by 60 to isolate the 23x.
805 = 23x
Divide each side 23
x = 35
35 cartridges have been used over the life of the printer