RosettaCodeData/Task/Integer-comparison/PowerShell/integer-comparison.ps1

11 lines
226 B
PowerShell
Raw Permalink Normal View History

2026-04-30 12:34:36 -04:00
$a = [int] (Read-Host a)
$b = [int] (Read-Host b)
if ($a -lt $b) {
Write-Host $a is less than $b`.
} elseif ($a -eq $b) {
Write-Host $a is equal to $b`.
} elseif ($a -gt $b) {
Write-Host $a is greater than $b`.
}