I'm not sure why this is so time complex. Can someone explain that to me.

```
int index = nums.size()-1, jumps = 0;
while(index != 0){
for(int i = 0; i < nums.size(); i++)
if(i+nums[i] >= index){
index = i;
break;
}
jumps++;
}
return jumps;
}```
```