How to validate input | Sololearn: Learn to code for FREE!


How to validate input

I want to validate input up to specific range.How to do it


5/24/2020 3:54:06 PM

Krushna Katore

2 Answers

New Answer


That can be done with help of if-else


you can use std::string there's method called Length use it to validate that input range or if you want the length of char * some_arg int length = sizeof(some_arg) / sizeof(char)