Computer Science, asked by anuska7471, 3 days ago

Wap to declare an array of size 15 and print first five elements from the array​

Answers

Answered by poojashukla1911
0

Answer:

arr[i] = ((i – 1) – k), where k is the index of arr[i – 1] that has appeared second most recently. This rule is applied when arr[i – 1] is present more than once in the array

arr[i] = 0. This rule is applied when arr[i – 1] is present only once or when i = 1.

Explanation:

mark me as brilliant please

Similar questions