Max. score: 100.00
Question 21
ਲ
Play with strings
Bob with his two friends Ben and Mike is playing a game with strings. Bob, Ben, and Mike have the strings P, Q, and
Reach of length M consisting of lowercase and uppercase English alphabets respectively
The beauty of string refers to the maximum occurrence of any substring in the string. For example, the beauty of
abcabdef is 2 as substring ab is occurring twice in the original string.
There are N rounds in this game in every turn, three of them must have
to change exactly one character of their string
and newly changed character should not be equal to the previously present
character.
After N rounds, one who has the resulting string with maximum beauty will be declared the winner. If more than one
has the resultant string with maximum beauty, it will be declared a draw.
0.0
All of the three friends play optimally.
Task
100.0
Determine the name of the person who has maximum beauty in its string after N rounds and has more beauty in its
string than the other two ie. "Bob" or "Ben" or Mike" If the rounds end in a draw.print Draw
8:09 PM
Example
18-Jun-21
Answers
Answered by
5
Answer:
xgyuhgsugdtnkzgjnv,gnskht
Answered by
0
which type of question is these
Similar questions