This can be solved by turning the information in the prompt into two equations, 20 = E + D, and (10 x D) - (15 x E) = M. For this, E represents the number of chocolates Madumita ate along the way, D represents the number of chocolates she successfully delivered, and M represents how much money she will receive from her cousin: what we are looking for. Since they give us the number she ate along the way (E), we can plug that in to the first equation to find D. ( 20 = 5 + D ----> 15 = D ) Now that we have E and D, we can plug them into the second equation to find M. (10 x 15) - (15 x 5) = M -----> 150 - 75 = 75Rs.
A line segment is represented (written) using letters for the start point and the end point, as in QR: QR is the line segment connecting Q to R. This is the most common case.
Expecially when we're not talking about points on a given line, a line can be refered to by any arbitrary name, such as "line f."