title: Solving a Linear Diophantine Equation(see description for examples)
body: <p>Let me start off by clarifying that(before you guys dismiss me), this is not a homework problem and I'm not a university student. :)</p>
  
  <p><strong>EDIT</strong>
  Thanks to @Klas and others, my question now boils down to a mathematical equation which needs to be solved programmatically.</p>
  
  <p>I'm looking for an algorithm/code which solves <code>Linear Diophantine Equation</code>.
  For lesser mortals like me, here's how such an equation looks like:</p>
  
  <p>Example 1: <code>3x + 4y + 5z = 25</code> (find all possible values of x,y,z)</p>
  
  <p>Example 2: <code>10p + 5q + 6r + 11s = 224</code> (find all possible values of p,q,r,s)</p>
  
  <p>Example 3: <code>8p + 9q + 10r + 11s + 12t = 1012</code> (find all possible values of p,q,r,s,t)</p>
  
  <p>I tried googling to no avail. I would have thought that some code would already be written to solve this. Do let me know if you guys have come across some kind of library which has already implemented this. And if the solution is in Java, nothing can be cooler!. Algorithm/pseudo code will also do. Thanks much.</p>