I found this question on Glassdoor :
Create a new array from an array of numbers. Start from the beginning. First put the number of some number, and then this number. For example, from the array 1, 1, 2, 3, 3, 1 you should get 2, 1, 1, 2, 2, 3, 1, 1 Write a program to solve this problem.
I'm not sure if I get the idea why 1, 1, 2, 3, 3, 1 is converted to 2, 1, 1, 2, 2, 3, 1, 1? At first I thought it was the number of occurrences of a number, followed by the number itself. But from this example, it seems that something else is needed.
What kind of transformation is this?
source share