/* package whatever; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
class Something {
// Imagine that this is a real class, that does real work.
public void doSomething(boolean b, char c, double d, int i) {
// Imagine that this is one of the main components of class Something.
System.
out.
println("Hi. You passed: " + b
+ ", " + c
+ ", " + d
+ ", and " + i
+ "."); }
public void doSomething(boolean b, char c, double d) {
doSomething(b, c, d, 42);
}
public void doSomething(boolean b, char c) {
doSomething(b, c, 1.3579);
}
public void doSomething(boolean b) {
doSomething(b, 'q');
}
public void doSomething() {
doSomething(true);
}
}
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
{
Something s = new Something();
Something t = new Something();
Something u = new Something();
// ...
s.doSomething(true, 'c', 2.9);
t.doSomething(false, 'z');
u.doSomething();
}
}
LyogcGFja2FnZSB3aGF0ZXZlcjsgLy8gZG9uJ3QgcGxhY2UgcGFja2FnZSBuYW1lISAqLwoKaW1wb3J0IGphdmEudXRpbC4qOwppbXBvcnQgamF2YS5sYW5nLio7CmltcG9ydCBqYXZhLmlvLio7CgpjbGFzcyBTb21ldGhpbmcgewoJLy8gSW1hZ2luZSB0aGF0IHRoaXMgaXMgYSByZWFsIGNsYXNzLCB0aGF0IGRvZXMgcmVhbCB3b3JrLgoJCiAgICBwdWJsaWMgdm9pZCBkb1NvbWV0aGluZyhib29sZWFuIGIsIGNoYXIgYywgZG91YmxlIGQsIGludCBpKSB7CiAgICAgICAgLy8gSW1hZ2luZSB0aGF0IHRoaXMgaXMgb25lIG9mIHRoZSBtYWluIGNvbXBvbmVudHMgb2YgY2xhc3MgU29tZXRoaW5nLgogICAgICAgIFN5c3RlbS5vdXQucHJpbnRsbigiSGkuIFlvdSBwYXNzZWQ6ICIgKyBiICsgIiwgIiArIGMgKyAiLCAiICsgZCArICIsIGFuZCAiICsgaSArICIuIik7CiAgICB9CgogICAgcHVibGljIHZvaWQgZG9Tb21ldGhpbmcoYm9vbGVhbiBiLCBjaGFyIGMsIGRvdWJsZSBkKSB7CiAgICAgICAgZG9Tb21ldGhpbmcoYiwgYywgZCwgNDIpOwogICAgfQoKICAgIHB1YmxpYyB2b2lkIGRvU29tZXRoaW5nKGJvb2xlYW4gYiwgY2hhciBjKSB7CiAgICAgICAgZG9Tb21ldGhpbmcoYiwgYywgMS4zNTc5KTsKICAgIH0KCiAgICBwdWJsaWMgdm9pZCBkb1NvbWV0aGluZyhib29sZWFuIGIpIHsKICAgICAgICBkb1NvbWV0aGluZyhiLCAncScpOwogICAgfQoKICAgIHB1YmxpYyB2b2lkIGRvU29tZXRoaW5nKCkgewogICAgICAgIGRvU29tZXRoaW5nKHRydWUpOwogICAgfQp9CgoKLyogTmFtZSBvZiB0aGUgY2xhc3MgaGFzIHRvIGJlICJNYWluIiBvbmx5IGlmIHRoZSBjbGFzcyBpcyBwdWJsaWMuICovCmNsYXNzIElkZW9uZQp7CglwdWJsaWMgc3RhdGljIHZvaWQgbWFpbiAoU3RyaW5nW10gYXJncykgdGhyb3dzIGphdmEubGFuZy5FeGNlcHRpb24KCXsKCSAgICBTb21ldGhpbmcgcyA9IG5ldyBTb21ldGhpbmcoKTsKCSAgICBTb21ldGhpbmcgdCA9IG5ldyBTb21ldGhpbmcoKTsKCSAgICBTb21ldGhpbmcgdSA9IG5ldyBTb21ldGhpbmcoKTsKCQoJICAgIC8vIC4uLgoJCgkgICAgcy5kb1NvbWV0aGluZyh0cnVlLCAnYycsIDIuOSk7CgkgICAgdC5kb1NvbWV0aGluZyhmYWxzZSwgJ3onKTsKCSAgICB1LmRvU29tZXRoaW5nKCk7Cgl9Cn0=
Hi. You passed: true, c, 2.9, and 42.
Hi. You passed: false, z, 1.3579, and 42.
Hi. You passed: true, q, 1.3579, and 42.