Skip to content

Instantly share code, notes, and snippets.

View Proektsoftbg's full-sized avatar

Ned Ganchovski Proektsoftbg

View GitHub Profile
@Proektsoftbg
Proektsoftbg / Multiline switch.cpd
Created March 27, 2024 08:11
Multiline switch function
f_1(x) = switch(x < 1; 1; _
x < 2; 2; _
x < 3; 3; _
x < 4; 4; _
x < 5; 5; _
x < 6; 6; _
x < 7; 7; _
x < 8; 8; 9)
f_2(x) = if(x > 9; 8; max(x - 1; 0))
$Plot{f_1(x) & f_2(x) @ x = 0 : 10}