Convert Boolean to String
public class Main {
/**
* Boolean to String conversion
*/
public void convertBooleanToString() {
boolean theValue = true;
//Do the boolean to String conversion
String theValueAsString = new Boolean(theValue).toString();
System.out.println(theValueAsString);
}
/**
* Starts the program
*
* @param args the command line arguments
*/
public static void main(String[] args) {
new Main().convertBooleanToString();
}
}
0 comments: