欢迎来到PP题库网 PP题库官网
logo

未知题型

在下面附属类方法中的下划线处应填入的正确参数是( )。 public void writeData(________) throws IOException{ GregorianCalendar calendar=new GregorianCalendar(); calendar.setTime(hireDay); out.println(name+'|'+salary+'|' +calendar.get(Calendar.YEAR)+'|' +(calendar.get(Calendar.MONTH)+1)+'|' +calendar.get(Calendar.DAY_OF_MONTH)); }
A.Employee[]e
B.employeE.dat
C.PrintWriter out
D.BufferedWriter

    A.setTime(hireDay);
    B.println(name+'|'+salary+'|'
    C.get(Calendar.YEAR)+'|'
    D.get(Calendar.MONTH)+1)+'|'
    E.get(Calendar.DAY_OF_MONTH));
    F.Employee[]e
    B.employeE.dat
    C.PrintWriter
【参考答案】

C
解析:本题考查考生对附属类的掌握。题目看起来很难,其实不用去理解程序即可回答,按照Java中的语法规则,只有......

(↓↓↓ 点击下方‘点击查看答案’看完整答案 ↓↓↓)

点击查看答案

相关考题

微信小程序免费搜题
微信扫一扫,加关注免费搜题

微信扫一扫,加关注免费搜题