I want to parse a string into a boolean value and I implemented this script ..
public static void test_lang_boole an(){
System.out.prin tln("boolean false from string "+Boolean.parse Boolean("Boolea n.FALSE"));
System.out.prin tln("boolean true from string "+Boolean.parse Boolean("Boolea n.TRUE"));
}
When I run this code,I get false for both..
I expected to get false for the first one and true for the second ..
Any1 can show me what's wrong here...
Thanks in adv
public static void test_lang_boole an(){
System.out.prin tln("boolean false from string "+Boolean.parse Boolean("Boolea n.FALSE"));
System.out.prin tln("boolean true from string "+Boolean.parse Boolean("Boolea n.TRUE"));
}
When I run this code,I get false for both..
I expected to get false for the first one and true for the second ..
Any1 can show me what's wrong here...
Thanks in adv
Comment