Char array

De Software testing
Ir para: navegação, pesquisa

The software asks the user a positive integer in the range of 1 to 20. Then it read a character sequence of that length. After it, the software asks a char and returns the position in the array in which the char is found for the first time or a message indicating that the char is absent in the array. The user has the option to look for several chars.

And what if a new input condition is added, such as 'number of times a character is searched in the array?