Computer Science, asked by sowmyagunti0055, 4 months ago

Hi,
Here is the question for the
first round of ATOM8 SDE
Intern interview:
There are n students in the
classroom. They are asked
to stand in a straight line
and they randomly arrange
themselves in a straight
line. You are allowed to ask
the student their names in a
sequence from student 1 on to
student n and multiple students
can have the same name. Write
an algorithm to print the names
and the count of the same
name in the same order which
they occur as u ask them.
Brute Force solutions will be
rejected please attempt with
more efficient solutions and
provide the Complexity of your
solution using Big O notation.
For Example
n=9
Alok, amit, suresh , amit, vidya,
sindhu, vidya, vidya, alok​

Answers

Answered by komal1414
0

Answer:

how long question........

Similar questions