17 Replies
@cupck Are you trying to write something like this in a file
1) Sentence
yea
What results are you seeing when you test your code
So this is saying that
i
is either greater than or equal to the length of the array
Array indices (which i is an index here) start at 0, so the max index you can have is the length minus 1
Look at your for statementone minute pls
like this ?
Not quite
Better though
Your index
i
can still be equal to the length of the array, the max index is length - 1omg
it worked
im so happy
thank you very much
Did you remove the
=
sign?yes
Perfect
Then your output formatting doesn't matter, can write i+1 if you want in the stream writer so it starts at 1
yea i got it
thank again
No problem
i never forget u
you save my life
I've been trying to fix this for two days
✅ This post has been marked as answered!