I can not find how to implement a design in C++. In the language of Delphi in case the operator can write the following design:
case s[j] of
'0'..'9','A'..'Z','a'..'z','_': doSomeThing();
How can i do the same in c++. Attracts me is the construction type 'a' .. 'z' and etc...
Thank you
You can do it using isalnum function as:
if(isalnum(s[j]) || (s[j] == '_') )
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With