title: Qt Questions about simple math calculations (PyQt, Qt4 C++)
body: <p>Im using PyQt and/or Qt4 C++ for the first time and trying create simple math calculations. What I need to do is use data from 2 inputs (QLineEdit) and run this calculation in the background:</p>
  
  <pre><code>a - b = c
  
  c * 2 = d / 0.9 = sum
  </code></pre>
  
  <p>The sum would then need to be printed on another QLineEdit. Is this possible in either PyQT or C++? An answer in either language would be much appreciated as I am using both.</p>
  
  <p>Also, just so all of my questions are out there, I have a number in QLineEdit and I need to find a data output based on a number range. Example:</p>
  
  <p>Input Number = 0.80</p>
  
  <pre><code>0 - 0.19 = 5 0.2 - 0.49 = 10 0.50 - 0.79 = 15 0.80 - 1.09 = 20
  </code></pre>
  
  <p>So the output (20 in this case) would need to also be output in another QLineEdit.</p>
  
  <p>Basically, the outputs are in QLineEdit because sometimes we need to change the value based on certain variables (weather, previous fertilizer applications, etc.) I am just a hobby programmer and I mainly work as a soil consultant so I am trying to build a program that inputs my lab data and I can run my calculations and speed up my turn around time. My company already runs calculations based in Excel and VB but I thought that it would be a fun project for me to try and build a new program in Qt. I have been spending countless hours in documentation, books, and tutorials and there are no answers anywhere. If there is any help that you can give me or at least give a link to something that may help, it would be greatly appreciated.</p>