在数据库系统中,用户所见数据模式为( )。
J2ME是为嵌入式和______提供的Java平台,它的体结构由profiles、Configuration和 Optional Packages组成。
下列的( )可以正确用以表示八进制值8。
三元条件运算符ex1?ex2:ex3,相当于下面______语句。 ( )
_____________方法是一种仅有方法头、没有具体方法体和操作实现的方法,该方法必须在抽象类之中定义。
请完善程序(程序文件名:Java_3.java)并进行调试。请在下画线处填入正确内容,然后删除下画线。请勿删除注释行和其他已有的语句内容。 [题目要求] 统计一个英文文本字符串包含的英文元音字母的个数,使程序的运行结果如下: The text contained vowels:88 源程序: public class Java_3 { public static void main(String[] args) { String text = " Beijing, the Capital City, is the political, " + "cultural and diplomatic centre of China. It has" + "become a modern international cosmopolitan city" + " with more than 11 million people. The Capital" + " International Airport, 23.5 km from the city centre," + "is China's largest and most advanced airport. " ; int vowels =0; int (1) = text.length(); for(int i = 0;i<textLength; i++) { char ch=Character.toLowerCase( text. (2) ); if(ch=='a'||ch=='e'||ch=='i'||ch=='o'||ch=='u') (3) ; } System.out.println( "The text contained vowels:" + vowels +"/n"); } }
下列程序实现从控制台输入并读取输出字符串。请将程序补充完整。 import java. io.*; publicClassCharInput { public static void main(StringArgsl[])throws java.io.IOException { String s: InputStreamReader ir; BufferedReader in; ir=new______(System.in): in=new______(ir): while(s=in.______!null) { System.out.println("Read:"+s): } } }
按位与运算:01010101&00101111=【 】。
在Windows环境下,当进行复制操作时,其复制的内容将存放在______中。
下列程序段执行后的输出结果为( )。 int x=3;int y=10: System.out.println(y%x):
paint()方法带有一个参数,它是java.awt.【 】类的一个实例。这个参数总是建立该Applet的panel的图形上下文。能用这个上下文在的Applet中绘图或写入文本。
请完善程序(程序文件名:Java_1.java)并进行调试。请在下画线处填入正确内容,然后删除下画线。请勿删除注释行和其他已有的语句内容。[题目要求]完成程序并运行,得到的结果如下图所示。源程序:importjavax.swing.JOptionPane;publicclassJava_1{ intx=0; Strings=(1); publicstaticvoidmain(Stringargs[]){ Java_1d=new(2); Stringoutput; output="Afterinstantiation:/n"+"x:"+d.x+"s:"+d.s; d.x=77; d.s="Goodbye"; output+="/nAfterchangingvalues:/n"+"x:"+d.x+"s""+d.s: JOptionPane.showMessageDialog(null,output,"DemonstratingPackageAccess", JOptionPane.INFORMATION_MESSAGE); System.exit(0); }}
下面声明和赋值语句中,错误的是( )。
JDBC的模型对开发数据库连接进行了改进,它包含()。
变量是程序中的基本存储单元之一,由变量名、______、变量属性、______组成。
以下( )可能包含菜单条。
给出下列的代码,哪行在编译时可能会有错误? ① public void modify() { ② int i,j,k; ③ i=100; ④ while(i>0) { ⑤ j=i*2; ⑥ System.out.println(" The value of j is"+ j); ⑦ k=k+1; ⑧ } ⑨}
类库主要包括核心java包、________________和org扩展包。
下面的程序是用do_while语句计算10的阶乘。请在程序的每条横线处填写一个语句,使程序的功能完整。 注意:请勿改动main()主方法和其他已有的语句内容,仅在横线处填入适当的语句。 源程序文件代码清单如下: public class DoWhileLoop { public static void main(________) { int n=10; long result=1; do { _______________ } ______________ System.out.println("10的阶乘为: "+result); } }
请在代码中的画线处填写正确的语句【 】,使程序输出hello world!。 //HelloApplet.java Import java.awt.*; Import java.applet.*; Public class HelloApplet extends { Public void paint(Graphics g) { _______ ("hello world! ",20,20); } }
