Problem in understanding math problem in japanese


I got question like this maybe some math question in japanese

179からある数これを引いたら、残りは12になりました。ある数はいくつですか。

Suppose x is the number that the question ask  
First i thought like x - 179=12  
Somewhat confuse with'これを引いたら’  
Is this mean there is a number and it is substracted by 179 or the number
itself 179??  
Particle を makes 179 like an object..  
Its ambiguous for me But the correct one is 179-x=12?




> 179 からある数これを引いたら、残りは12。数字はいくらですか

As narto said in his comment the above sentence or the math problem is very
clumsy and almost ungrammatical.

I would edit the math problem like:

> 179からある数を引いたら、残りは12になりました。ある数はいくつですか。

179 - X = 12

This teacher has to learn Japanese before they try to start teaching math!

