I know a few ways how to check this. regex,int.parse,tryparse,looping.
int.parse
tryparse
can anyone tell me what is the fastest way to check?
the nee
You can do this in a one line LINQ statement. OK, I realise this is not necessarily the fastest, so doesn't technically answer the question, but it's probably the easiest to write:
str.All(c => c >= '0' && c <= '9')