How i can do that whats wrong?


#1


whats wrong


#2

There is a problem here:

Can you spot it now?


#3

what i need to do? delete that?


#4

That is a bit drastic. If you deleted it, what would you put in its place? What purpose does it have -- can you put that into words?


#5

MAN JUST HELP ME sry caps


#6

I'm trying to help you understand what you are doing. When you write programs you will spend more time debugging than writing so you might as well start picking up a few skills in that area.

You don't seem to understand why you've written

i < name.length

In a for loop you have these sections:

for (where to start; when to stop; change the counter)

You've said that you want to stop looping when:

i < name.length

Tell me what does name.length mean?


#7

It shows how much letters are in the word


#8

@lucbat1, theres no need to delete that specific part of your program. @albionsrefuge is trying to say that you need to analyze and understand what you had written or what your are doing.

For clarification, where did you get your variable name in name.length ?
As you can see, your variable holding your array is names.

See the difference? The variable names that you declared above holding your array is the one you will use in your for loop when to stop section.

Hope this helps.


#9

thank you I typed too fast


#10

Thank you for helpe me to understand, i alread understand it, but here is just a type error


#11

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.