Advertisement
Guest User

tak

a guest
Jan 17th, 2018
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. <form action="" method="GET" />
  2. Wpisz 1 liczbe: <input type="text" name="a" value="" /><br />
  3. Wpisz 2 liczbe: <input type="text" name="b" value="" /><br />
  4. Wpisz 3 liczbe: <input type="text" name="c" value="" />
  5. <input type="submit" value="Wyślij" name="przycisk">
  6. </form>
  7.  
  8. <?php
  9. if (isset($_GET['przycisk']));
  10. {
  11. $a=$_GET['a'];
  12. $b=$_GET['b'];
  13. $c=$_GET['c'];
  14. function funkcja1($a,$b,$c)
  15. {
  16. if($a<$b&&$a<$c){
  17. return $a;
  18. }
  19. else if($b<$a&&$b<$c){
  20. return $b;
  21. }
  22. else if($c<$a&&$c<$b){
  23. return $c;
  24. }
  25. }
  26. echo "<br>"."Najmniejsza liczba to: ".funkcja1($a,$b,$c);
  27. }
  28. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement