title: php calculation keeps getting the answer as 0
body: <p>this is the index.php file</p>
  <pre><code>if(isset($_POST['submit']))
  {
      echo header('Location:answer.php');
  }
  ?&gt;
  
  &lt;!DOCTYPE html&gt;
  &lt;html lang=&quot;en&quot;&gt;
  &lt;head&gt;
      &lt;meta charset=&quot;UTF-8&quot;&gt;
      &lt;meta http-equiv=&quot;X-UA-Compatible&quot; content=&quot;IE=edge&quot;&gt;
      &lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1.0&quot;&gt;
      &lt;title&gt;Document&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
      &lt;div class=&quot;container&quot;&gt;
          &lt;form method=&quot;post&quot;&gt;
              &lt;div class=&quot;form-group&quot;&gt;
                  &lt;label&gt; Insert P value &lt;/label&gt;
                  &lt;input type=&quot;text&quot; name=&quot;p&quot; placeholder=&quot;please insert your P value&quot;&gt;
  &lt;/div&gt;
  &lt;br&gt;
  
  &lt;div class=&quot;form-group&quot;&gt;
      &lt;label&gt; Insert R value &lt;/label&gt;
      &lt;input type=&quot;text&quot; name=&quot;r&quot; placeholder =&quot;please insert your R value &quot;&gt;
      
  &lt;/div&gt;
  &lt;br&gt;
  &lt;div class=&quot;form-group&quot;&gt;
      &lt;label&gt; Insert your N value &lt;/label&gt;
  
      &lt;input type=&quot;text&quot; name=&quot;n&quot; placeholder=&quot; please insert your N value&quot;&gt;
  
  &lt;/div&gt;
  &lt;br&gt;
      &lt;button type=&quot;submit&quot; name=&quot;submit&quot; &gt; Submit &lt;/button&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  <p>this is the answer.php file</p>
  <pre><code>&lt;?php
  
  $p=isset($_POST['p'])?$_POST['p']: &quot; &quot;;
  $r=isset($_POST['r'])?$_POST['r']:&quot; &quot;;
  $n=isset($_POST['n'])?$_POST['n']: &quot; &quot;;
  $si=(int)$p*(int)$r*(int)$n/100;
  echo &quot;Hello this is the final answer &quot;.$si;
  ?&gt;
  </code></pre>
  <p>i want the answer to be displayed in another page that is answer.php but whatever number i am inserting i keep getting the answer as 0. Please help and thank you.</p>