• + 0 comments

    In the first loop we are inserting the values to each ith indices of the array . In the second loop we are displaying the inserted values of the respectve ith indices starting from 0 to n.

    Here is my solution for better understanding https://www.codinghumans.xyz/2020/08/java-1d-array-hackerrank-solution-by.html