FOR LOOP initialisation condition

in this problem how are we using ‘i’ in the loop

Hello @Aryan-Sharma-2421953867913946m,

As we have have to perform the logic written inside the for loop n times i.e. for each element we are going to read as input.

So, i is working as a counter that is used to define the total number of iterations of for loop we are going to perform.

Hope, this would help.
give a like if you are satisfied.

1 Like