RosettaCodeData/Task/Determine-if-a-string-is-numeric/PL-I/determine-if-a-string-is-numeric.pli
Ingy döt Net d066446780 langs a-z
2013-04-10 22:43:41 -07:00

12 lines
239 B
Text

is_numeric: procedure (text) returns (bit (1));
declare text character (*);
declare x float;
on conversion go to done;
get string(text) edit (x) (E(length(text),0));
return ('1'b);
done:
return ('0'b);
end is_numeric;