Giventhatcisareferencetoavalidjava.io.Consoleobject,whichtwocodefragmentsreadalineoftextfromtheconsole?() A.Strings=c.readLine();B.char[]c=c.readLine();C.Strings=c.readConsole();D.char[]c=c.readConsole();E.Strings=c.readLine(%s,name);F.char[]c=c.readLine(%s,name);
Giventhatcisareferencetoavalidjava.io.Consoleobject,whichtwocodefragmentsreadalineoftextfromtheconsole?()
A.Strings=c.readLine();
B.char[]c=c.readLine();
C.Strings=c.readConsole();
D.char[]c=c.readConsole();
E.Strings=c.readLine("%s","name");
F.char[]c=c.readLine("%s","name");
相关考题:
Giventhatcisareferencetoavalidjava.io.Consoleobject,and:11.Stringpw=c.readPassword(%s,pw:);12.System.out.println(got+pw);13.Stringname=c.readLine(%s,name:);14.System.out.println(got,name);Iftheusertypesfidowhenpromptedforapassword,andthenrespondsbobwhenpromptedforaname,whatistheresult?()A.AnexceptionisthrownatruntimeB.pw:fidogotfidoname:bobgotbobC.pw:gotfidoname:bobgotbobD.Compilationfails.