Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
dvprog_11 [2017-02-27 09:44] Daniel Viström |
dvprog_11 [2017-02-27 09:53] Daniel Viström |
||
---|---|---|---|
Line 14: | Line 14: | ||
*/ | */ | ||
function summa($tal1, | function summa($tal1, | ||
+ | $summa = $tal1 + $tal2; | ||
+ | $tal1 = 1000; // $tal ändras bara i funktionen. | ||
$test = ' | $test = ' | ||
echo $test . '< | echo $test . '< | ||
- | $summa = $tal1 + $tal2; | ||
- | $tal1 = 1000; // $tal ändras bara i funktionen. | ||
return $summa; | return $summa; | ||
} | } | ||
Line 70: | Line 69: | ||
// Värdet som returneras kan skrivas ut eller | // Värdet som returneras kan skrivas ut eller | ||
// sparas i en variabel. | // sparas i en variabel. | ||
- | echo strrev(' | + | echo strrev(' |
$text=' | $text=' | ||
$text2=strrev($text); | $text2=strrev($text); |