Erste If, Else und Elseif verzweigung

This commit is contained in:
onur 2025-02-22 21:26:58 +01:00
parent 7e2dbaf4a0
commit ab300e7990
2 changed files with 9 additions and 0 deletions

View File

@ -0,0 +1,9 @@
$farbe = Read-Host "Was ist deine lieblingsfarbe?"
if($farbe -eq "rot") {
Write-Host "Gute Wahl!"}
elseif($farbe -eq "blau") {
Write-Host "Stabil Bruder!"}
elseif($farbe -eq "schwarz") {
Write-Host "Geht besser, aber geht!"}
else {
Write-Host "$farbe ist scheiße!"}

Binary file not shown.