Guest User

Untitled

a guest
Jan 20th, 2019
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. <html>
  2.  
  3. <body>
  4.  
  5. <?php
  6.  
  7. $h = $_POST["name1"];
  8. $M = $_POST["name2"];
  9.  
  10.  
  11. $t = 1;
  12.  
  13. while ($t<$M) {
  14.  
  15. 0<=$h and $h<=100;
  16. 0<$M and $M<240;
  17.  
  18. $A = (-6 * pow($t, 4)) + ($h * pow($t, 3)) + (2 * pow($t, 2)) + $t;
  19.  
  20. $t++;
  21. }
  22.  
  23. echo $A;
  24. echo "<br/>";
  25. echo $t;
  26. echo "<br/>";
  27. if ($A <= 0) {
  28. break;
  29. }
  30.  
  31.  
  32.  
  33.  
  34. echo "The balloon first touches the ground at $t hour";
  35.  
  36.  
  37. if ($t > $M) {
  38. echo "The balloon does not touch the ground during the given time";
  39. }
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46. ?>
  47.  
  48. </body>
  49.  
  50. </html>
Add Comment
Please, Sign In to add comment