RosettaCodeData/Task/Conditional-structures/Lapyst/conditional-structures-1.lapyst
2026-04-30 12:34:36 -04:00

15 lines
209 B
Text

if cond then
foo();
elsif cond then
bar();
else
baz();
end
// if's are expressions and can yield the value of the last expression in each branch
var int x = if y > z then
y + 1
else
z
end
;