/* package whatever; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
private static char cube(char c) {
char result;
result = (char) (c *c *c);
return result;
}
{
char ch = '3';
int result = cube(ch);
// Call the method that accepts a char
System.
out.
println("Cubed 'char' = " + result
); System.
out.
println("Cubed 'char' = " + cube
(ch
)); }
}
LyogcGFja2FnZSB3aGF0ZXZlcjsgLy8gZG9uJ3QgcGxhY2UgcGFja2FnZSBuYW1lISAqLwoKaW1wb3J0IGphdmEudXRpbC4qOwppbXBvcnQgamF2YS5sYW5nLio7CmltcG9ydCBqYXZhLmlvLio7CgovKiBOYW1lIG9mIHRoZSBjbGFzcyBoYXMgdG8gYmUgIk1haW4iIG9ubHkgaWYgdGhlIGNsYXNzIGlzIHB1YmxpYy4gKi8KY2xhc3MgSWRlb25lCnsKCXByaXZhdGUgc3RhdGljIGNoYXIgY3ViZShjaGFyIGMpIHsKCSAgICBjaGFyIHJlc3VsdDsKCSAgICByZXN1bHQgPSAoY2hhcikgKGMgKmMgKmMpOwoJICAgIHJldHVybiByZXN1bHQ7Cgl9CgkKCXB1YmxpYyBzdGF0aWMgdm9pZCBtYWluIChTdHJpbmdbXSBhcmdzKSB0aHJvd3MgamF2YS5sYW5nLkV4Y2VwdGlvbgoJewoJCWNoYXIgY2ggPSAnMyc7CgkJaW50IHJlc3VsdCA9IGN1YmUoY2gpOwoJCS8vIENhbGwgdGhlIG1ldGhvZCB0aGF0IGFjY2VwdHMgYSBjaGFyCgkJU3lzdGVtLm91dC5wcmludGxuKCJDdWJlZCAnY2hhcicgPSAiICsgcmVzdWx0KTsKCQlTeXN0ZW0ub3V0LnByaW50bG4oIkN1YmVkICdjaGFyJyA9ICIgKyBjdWJlKGNoKSk7Cgl9Cn0=