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_02 [2020-08-26 16:57] Daniel Viström |
dvprog_02 [2020-09-03 13:07] Daniel Viström |
||
---|---|---|---|
Line 76: | Line 76: | ||
| | ||
// && betyder " | // && betyder " | ||
- | if ($name1 == '4Bertil' && $name2 == '3Stina') { | + | if ($name1 == 'Bertil' && $name2 == 'Stina') { |
echo 'Båda villkoren är sanna.< | echo 'Båda villkoren är sanna.< | ||
} | } | ||
Line 88: | Line 88: | ||
if (!($tal1 == 6)){ // Blir samma som: if ($tal1 != 6){ | if (!($tal1 == 6)){ // Blir samma som: if ($tal1 != 6){ | ||
echo 'Talet är inte 6< | echo 'Talet är inte 6< | ||
+ | } | ||
+ | |||
+ | if ($tal1 == 100) { | ||
+ | echo ' | ||
+ | } else { // else = " | ||
+ | echo 'Inte 100< | ||
} | } | ||