11-Java软件工程师面试题.docx
姓名:面试日期与时间:年月日:为了更全面地了解你的专业能力,请你尽力回答以下问题,谢谢合作!1. SQLSERVER有numeric类型自动序列递增,请简述一下ORACLE中是如何实现序列自动自增功能的。2. 写出ORACLE中的日期函数。3. 简述一下STRUCTS的组成和处理过程。4. Whatwillbetheoutputwhenyoucompileandexecutethefollowingprogram,publicclassBaseprivatevoidtest()inti=1;switch(i)caseO:System.out.println("zero);break;case 1:System.out.println("onen);case 2:System.out.println("two");default:System.out.println(,'default);)staticpublicvoidmain(Stringa)newBase().test();Selectmostappropriateanswer.a) oneb)one,defaultc) one,two,defaultd)defaulte) CompilationError,switchcannottakeanintasanargument5. Forwhatvalueofi,thefollowingprogramwilloutput"Lessthan20"publicclassBaseprivatevoidtest()inti;if(i<10)System.out.println("Lessthan10);elseif(i<20)System.out.println(,'Lessthan20");elseSystem.out.println(,'Notlessthan10);)staticpublicvoidmain(Stringa)newBase().test();)Selectallappropriateanswers.a)0b)10c)11d)19.999;e)(int)19.99f)None6. Forwhatvalueofi,thefollowingprogramwilloutput"NotGreaterthan10"publicclassBaseprivatevoidtest()inti;if(i>10)System.out.println(,Greaterthan10n);elseif(i<10)System.out.println("Lessthan10");elseif(i>20)System.out.prinlln("Greaterthan20");elseSystem.out.println("NotGreaterthan10u);1staticpublicvoidmain(Stringa)newBase().test();Selectmostappropriateanswer.a)0b)10c)11d)100e)None7. Themethodtest()throwsanIOException.Howdoyouspecifythat?importjava.io.*;.*;publicclassBaseprivatevoidtest()(Stringa=null;if(a=null)/throwsIOExceptionSelectallvalidanswersa)privatevoidtest()throwIOExceptionb)privatevoidtest()thrownewIOExceptionDc)privatevoidtest()throwsIOException()d)privatevoidtest()throwsIOExceptione)privatevoidtest()raiseIOException答题区:答题区:2.3.4.5.6.答案:1.通过设置序列DatetimetimestampMVCmodelviewcontrobcdb7.d