A shopkeeper buys a number of blue pens and red pens. He pack 3 blue pens and 2 red pens into a packets for sale. If he wants to obtain 160 packets of the pens he needs another 25 blue pens. What is the total number of the pens bought by him at first?

160*3 number he needs, he is short 25.

He bought 160*3-25.

To find the total number of pens bought by the shopkeeper at first, we can set up equations and solve for the unknown values.

Let's use variables to represent the quantities:
Let B be the number of blue pens initially bought,
and R be the number of red pens initially bought.

From the given information, we know that the shopkeeper packs 3 blue pens and 2 red pens into each packet for sale.
Therefore, the number of packets can be represented as: 160 packets = (3 blue pens + 2 red pens) = 5 pens per packet.

So, if the shopkeeper wants to obtain 160 packets, there would be a total of 160 * 5 = 800 pens in those packets.

We are also given that the shopkeeper needs another 25 blue pens to reach this total of 800 pens.

Now we can set up equations based on the information given:

1. The total number of blue pens initially bought is B:
B + 25 (additional blue pens) = 800 (total pens)

2. The total number of red pens initially bought is R:
R = (800 - 25) / 5 = 775 / 5 = 155.

So, the total number of pens bought by the shopkeeper at first is:
B + R = B + 155.

Unfortunately, the number of blue pens initially bought (B) is not given in the question, so we can't find the exact total number of pens bought.