int i, j ;
String[] types = { "symbol", "name", "address" };
String[][] data = { {"IBM",
"International Business Machines",
"Armonk, NY" },
{"MACR",
"Macromedia",
"Newton, MA" },
{"CSCO",
"Cisco Systems",
"San Jose, CA" } };
for ( i = 0 ; i < types.length ; i++ )
if ( types[i].equals( dataType ) ) break ;
if ( i == types.length )
return( "Unknown dataType: " + dataType );
for ( j = 0 ; j < data.length ; j++ )
if ( data[j][0].equals( symbol ) ) break ;
if ( j == data.length )
return( "Unknown symbol: " + symbol );
return( data[j][i] );