Neither...
Well, first solution is the least ugly of the two.
But since all data are related (or seems to be, if I follow the array6 example), it is better to group them in the same unit.
For this, you can create a class:
Code:class Stuff
{
String smallTalk;
String answer;
String topic;
float oneValue;
float anotherValue;
SomeInformation(String st, String a, String t, float ov, float av)
{
smallTalk = st;
answer = a;
topic = t;
oneValue = ov;
anotherValue = av;
}
}
Of course, you should find more significant class name and field names...
Then you initialize as:
Code:Stuff[] info =
{
new Stuff("Hello", "Yes", "Question", 0.0, 3.0),
new Stuff("Goodbye", "No", "Answer", "1.0", "4.0"),
new Stuff("What's Up?", "Maybe", "Unknown", "2.0", "5.0")
};
Moreover, it maintains consistency, which is harder with independent arrays.
Thus, as I see your second question while I type this answer, you can sort the array according to whatever field you want, relation between data is preserved.
To sort an array of objects, you have to look into Comparable or Comparator classes (interfaces). Something raised from time to time in the forum, a quick search should give hints.