You are not logged in.
Pages: 1
I need to filter out certain values of numeric text that is in a .txt file,
and retain the narrative that is irregularly distributed throughout.
A few thousand lines numeric only; maybe two dozen lines alpha only.
I traverse the file with FOR whose DO is an IF that does GEQ comparison
for filtering the numbers.
Problem is that the alpha always evaluates as true, i.e. GEQ any number.
I need it to fail instead.
Can you help?
Of course it works to test first all lines against an alpha value,
known not to exist in thousands of the lines,
in pursuit of the few alpha lines.
Probably offends your sensibilities as it does mine.
Offline
if "abc" LSS 0 Echo we found a non numeric string
Offline
Thanks. I'm sure that I will use it someday for something.
Given that it does not avoid the double comparison,
what I did instead was to suffix the narrative lines with a number,
thus every line is processed in one comparison.
Offline
Pages: 1