Shortest Impossible Sequence of Rolls
You're provided with an integer array, rolls, of length n, and an integer, k. You roll a k-sided dice numbered from 1 to k, n times, where the result of the ith roll is rolls[i].
Your task is to print the length of the shortest sequence of rolls that cannot be obtained from rolls.
A sequence of rolls of length len is defined as the result of rolling a k-sided dice len times.
Ada AI
I want to discuss a solution
Help me solve this
Give more examples
What's wrong with my code?
How to use 'for loop' in javascript?
javascript (node 13.12.0)