11 lines
223 B
Text
11 lines
223 B
Text
isNumeric := proc(s)
|
|
try
|
|
if type(parse(s), numeric) then
|
|
printf("The string is numeric."):
|
|
else
|
|
printf("The string is not numeric."):
|
|
end if:
|
|
catch:
|
|
printf("The string is not numeric."):
|
|
end try:
|
|
end proc:
|