basic_string
strtok()
char* input = "20-21-3-1-22-2-4"; int num1 = 0, num2 = 0, num3 = 0, num5 = 0, num6 = 0, num7 = 0; if( sscanf( input, "%d-%d-%d-%d-%d-%d-%d", &num1, &num2, &num3, &num5, &num6, &num7) != 7 ) { ; // Process invalid format }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)