[填空题] 阅读下面代码: import java.awt.*; public class Exam11_1 { private frame f; private Button b1,b2,b3,b4; public static void main(String args[] { Exam11_1 that = new Exam11 1 (); that.go(); } public void go() { ______; f.setLayout(new FlowLayout()) ;; b1 = new Button ("Button 1"); b2 = new Button ("Button 2"); b3 = new Button ("Button 3"); b4 = new Button ("Button 4"); f.add (b1); f.add (b2); f.add (b3); f.add (b4); f.pack (); f.setVisible (true);} } 请在程序中画线处填写正确的语句 【13】 ,以便编译运行程序后得到正确的结果。
正确答案:f=new frame("GUI example")
参考解析:本题考查容器和布局管理器的基本知识,属于综合题。在本程序里,缺少建立frame的语句,而且该frame的名字为GUI example,而4个按钮的布局方式被压缩至最小,因此是 FlowLayou布局方式。


![[填空题] 阅读下面代码: import java.awt.*; public class Exam11 [填空题] 阅读下面代码: import java.awt.*; public class Exam11](http://www.mshxw.com/aiimages/31/481505.png)
