java - Issue with contains() method -


I am writing a simple code using the () method, but the problem is That if I put a string array in the argument of method () , nothing in the program (no error), so it should just loop over a string array and see if it contains There is an element from the other arrow. I tried with a word in logic and it works fine arrays are not empty and I can print them. So, any suggestions?

This is a part of the code:

 for  (int i = 0; i & lt; farbe.length; i ++) {for (int jm = 1; j & lt; names.length; j ++) {if (name [j] is included (fürb [i])) {System.out.println (name [ja] + "\ t" + "Yes "); }}}   

array elements. * Reading from the txt file. Therefore, there is a word sequence in the 'Name' array and there is color in the 'color' array. Parts of the Arrays:

Name:

Hernelderjekke & gt; & Gt; Collins
Helenstoffjke & gt; MH 7 4B
9-LV (Schwarz | 54)
9-LV (Schwarz | 52)
Tunica-Leiderclide & gt; 9519

color:

beige
br> schwarz

arrays are big, so I I keep a little bit of part.

Your problem may be that the Java array starts with index 0. Also, try the wrong place in the line included in your braces: for (int i = 0; i & lt; farbe.length; i ++) {for (int j = 0; j & lt; names.length; j ++) {if arrays include (names [j] (include [[]] [system] "+" Yes ");}}

Comments

Popular posts from this blog

excel vba - How to delete Solver(SOLVER.XLAM) code -

github - Teamcity & Git - PR merge builds - anyway to get HEAD commit hash? -

ios - Replace text in UITextView run slowly -