Giventhatcisareferencetoavalidjava.io.Consoleobject,and:11.Stringpw=c.readPassword("%

题目内容(请给出正确答案)

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.Anexceptionisthrownatruntime

B.pw:fidogotfidoname:bobgotbob

C.pw:gotfidoname:bobgotbob

D.Compilationfails.

如果没有搜索结果或未解决您的问题,请直接 联系老师 获取答案。