using System;
public class Test
{
public static void Main( )
{
System.Collections .ArrayList lista1 = new System.Collections .ArrayList ( ) ;
lista1.Add ( 13 ) ;
lista1.Add ( 113 ) ;
System.Collections .ArrayList lista2 = new System.Collections .ArrayList ( ) ;
lista2.Add ( "Blog xCSw" ) ;
lista2.Add ( "Blog AndroiDEV" ) ;
int numeroEntero = lista1[ 0 ] ;
Console.WriteLine ( numeroEntero.ToString ( ) ) ;
string cadena = lista2[ 0 ] ;
Console.WriteLine ( cadena) ;
}
}
dXNpbmcgU3lzdGVtOwoKcHVibGljIGNsYXNzIFRlc3QKewoJcHVibGljIHN0YXRpYyB2b2lkIE1haW4oKQoJewoJCVN5c3RlbS5Db2xsZWN0aW9ucy5BcnJheUxpc3QgbGlzdGExID0gbmV3IFN5c3RlbS5Db2xsZWN0aW9ucy5BcnJheUxpc3QoKTsKCQlsaXN0YTEuQWRkKDEzKTsKCQlsaXN0YTEuQWRkKDExMyk7CgkJCgkJU3lzdGVtLkNvbGxlY3Rpb25zLkFycmF5TGlzdCBsaXN0YTIgPSBuZXcgU3lzdGVtLkNvbGxlY3Rpb25zLkFycmF5TGlzdCgpOwoJCWxpc3RhMi5BZGQoIkJsb2cgeENTdyIpOwoJCWxpc3RhMi5BZGQoIkJsb2cgQW5kcm9pREVWIik7CgkJCgkJaW50IG51bWVyb0VudGVybyA9IGxpc3RhMVswXTsKCQlDb25zb2xlLldyaXRlTGluZShudW1lcm9FbnRlcm8uVG9TdHJpbmcoKSk7CgkJCgkJc3RyaW5nIGNhZGVuYSA9IGxpc3RhMlswXTsKCQlDb25zb2xlLldyaXRlTGluZShjYWRlbmEpOwoJfQp9
compilation info
prog.cs(15,21): error CS0266: Cannot implicitly convert type `object' to `int'. An explicit conversion exists (are you missing a cast?)
prog.cs(18,24): error CS0266: Cannot implicitly convert type `object' to `string'. An explicit conversion exists (are you missing a cast?)
Compilation failed: 2 error(s), 0 warnings
stdout