RosettaCodeData/Task/Empty-string/XPL0/empty-string.xpl0

11 lines
221 B
Plaintext

code Text=12;
string 0; \use zero-terminated convention, instead of MSb set
char S;
[S:= ""; \assign an empty string
if S(0) = 0 then Text(0, "empty
");
S:= "Hello";
if S(0) # 0 then Text(0, "not empty
");
]