请完善程序(程序文件名:Java_2.java)并进行调试。请在下画线处填入正确内

题型:填空题

问题:


请完善程序(程序文件名:Java_2.java)并进行调试。请在下画线处填入正确内容,然后删除下画线。请勿删除注释行和其他已有的语句内容。
[题目要求]
完善程序,使程序运行结果如下图所示。


源程序:
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class Java_2 {
 public static void main(String[] args) {
  RadioButtonFrame frame=new RadioButtonFrame();
  frame.setDefauhCloseOperation(JFrame.EXIT_ON_CLOSE);
   (1)
  }
}
class RadioButtonFrame extends JFrame {
 public RadioButtonFrame() {
  setTitle("Radio按钮实例");
  setSize(DEFAULT_WIDTH,DEFAULT_HEIGHT);
  Container contentPane=getContentPane();
  label=new JLabel("热烈庆祝Java程序语言开考三周年");
  label.setForeground(Color.yellow);
  contentPane.setBackground(Color.red);
  label.setFont(new Font("黑体",Font.PLAIN,DEFAULT_SIZE));
  contentPane.add(label,BorderLayout.CENTER);
  buttonPanel=new JPanel();
  group=new ButtonGroup();
  addRadioButton("小",8);
  addRadioButton("中",12);
  addRadioButton("大",18);
  addRadioButton("特大",30);
  contentPane.add(buttonPanel,BorderLayout.SOUTH);
 }
  public void addRadioButton(String name,final int size) {
   boolean selected=size==DEFAULT_SIZE:
   JRadioButton button=new (2) (name,selected);
   group.add(button);
   buttonPanel.add(button);
   ActionListener listener=new Action Listener() {
    public void actionPerformed( (3) evt){
     label.setFont(new Font("黑体",Font.PLAIN,size));
    }
   };
   button.addActionListener( (4) );
  }
  public static final int DEFAULT_WIDTH=340;
  public static final int DEFAULT_HEIGHT=200:
  private JPanel buttonPanel;
  private ButtonGroup group;
  private JLabel label;
  private static final int DEFAULT_SIZE=12;
}


考点:计算机等级考试JAVA二级JAVA机试
题型:填空题

根据句意及首字母完成单词。

1.What l________ do you speak?

2. Guangzhou is in the s________ of China.  

3. W              _to our school. We are kind to all our friends.

4. You can borrow all kinds of books from the l_________.

5. Look!Your hands are so d             __. Please wash (洗) them.

6. On weekends , we usually sleep l _________.

7. This lion is lazy. It usually r________  twenty hours every day.

8. Our teacher is f________ to us so we like her very much.

9. My grandma often tells me s________ about Lei Feng.

10. The pay phone is b_________ the post office and  the library.

题型:填空题

中国国际经济地位提高的主要表现有哪些?

题型:填空题

换挡之前应()离台器踏板。

A.完全踩下

B.部分踩下

C.部分抬起

D.完全抬起

题型:填空题

法规草案只能由有权提出法规案的机关、市人民代表大会代表或者市人大常委会组成人员组织起草。

题型:填空题

上海世博会上,各国展馆纷纷展示本民族文化的独特风采,如丹麦“小美人鱼”、卢森堡的“金色少女”像…….同时,许多外国展馆也都嵌入了中华文化元素,如意大利馆的“福”字,挪威馆的“中国红”……

结合材料,从文化生活的角度分析为什么文化既是民族的,又是世界的?

更多题库