When I run the program mentioned above I get the output of:
[[Ljava.lang.String;@1ad086a, [Ljava.lang.String;@10385c1]
Anyway I tried to play with it to access just one individual element but still didn't have much luck. This is what I did:
import java.util.*;
public class LinkTester {
public static void main(String[] args) {
// 2-dimensional array is an array of arrays...
String[][] myStrings = { { "abc", "def" }, { "ghi", "jkl" } };
// so the list holds single-dimension String arrays...
List<String[]> list = Arrays.asList(myStrings);
System.out.println("The answer is:" + list.get(1) );
}
}
It returned:
The answer is:[Ljava.lang.String;@12dacd1
Is that the memory location the value is being stored? I will continue to do
testing but the fire pit looks better and better.