Sailaja K writes:
>         String[][] nameArrayForPerson= new String[3][2];
> (...)
>         JOptionPane.showMessageDialog(null,nameArrayForPerson[max] + 
> "  has longest first name");
>        
>
>
>
Hi!

Above lines tells all the truth about error :) You try to display 2D 
array using only one index. Use two indexes for display [max][0] for 
first name and [max][1] for surname.

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/javaprogrammingwithpassion?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to