The strikes are serious protests about serious issues, but I'm struck, as so often on these occasions, by something much more mundane. People are once again talking to people; strangers are going out of their way to befriend strangers, allies for a week or two in their shared frustration. Parisian motorists, even, normally the most competitive of individualists, have been seen leaving notes in their parked cars saying where they are going and when they expect to leave in case anymore wants a lift.
Remove the technology of modem life, it seems, and we often start to be nice to one another again. Technology can isolate us, for all its benefits. It started, I guess, with the chimney. Before there were chimneys, we all had to huddle together in one room Just to keep warm, master and maid, cowman and son of the house. Then some unknown genius came up with the idea of the chimney, and the social stratification of society increased dramatically as all withdrew into their own quarters. Central heating, which is, more truthfully, decentralized heating, made it worse, and now we have our walkmans, our microwaves, or, if we' re really trendy, the Internet and e-mail. You can get by, these days, without actually speaking to anyone at all. Just the odd grunt to show that you' re alive !
I liked the survey which asked teenagers how they laid a table for a meal. Did they put the knife on the fight and the fork on the left, or did they put them both together? And 40 percent said one and 20 percent the other, but 40 percent didn't know! They had never sat down at a table together but had always, as they say, been grazers, helping themselves from the fridge and carrying the food off to their own comer to munch on their own.
If progress means that we don' t need to talk to each other anymore, then I'm getting worried. You can' t begin to love and befriend your neighbors if you never talk to them, and vice versa, they can't love you. It becomes a recipe for a world of solitaries. But most of us weren't destined to be hermits. People need people to be truly people, as the Parisians, in spite of all their frustrations, are discovering again this week. "Try walking instead" was my motto for this morning, but perhaps the motto for us all this festive month might be "Turn it off, whatever it is, and try talking instead!"
According to the author, the advent of modem technology may NOT______.
A.isolate us from the test of the society.
B.enable us to enjoy a much more convenient life.
C.leave people alone so that they may become truly people.
D.help people become grazers who are used to helping themselves from the fridge and carrying the food off to their own comer to munch on their own.
第1题
将下面Applet程序补充完整。
import java.awt.*:
import java.apptet.*;
public class Hi ______ {
public void paint(Graghics g) {
g.drawstring("Hi!",2.5,2.5);
}
}
第2题
下列程序构造了一个 Swing Applet ,请在下划线处填入正确的代码
Import javax.swing.*;
Import java.awt.*;
Public class SwingApplet extends 【 13 】 {
Jlabel l = new Jlabel (“ This is a Swing Applet. ” );
Public void init(){
Container contentPane = getContentPane();
contentPane.add(1);
}
}
第3题
下面程序构造了一个Swing Applet,在下画线处填入正确的代码。
import javax.swing.*;
import java.awt.*;
public class SwingApplet extends ______ {
JLabel 1=new JLabel("This is a Swing Applet.");
public void init() {
Container contentPane=getContentPane();
contentPane.add(1);
}
}
第4题
下面程序的输出结果是()。 import java.awt.*; import java.applet.*; public class HelloApplet extends Applet { public void paint(Graphics g) { g.drawstring("Hello World!", 20, 20); } }
A.20,20
B.Hello World!
C.编译不能通过
D.以上都不对
第5题
在下面Java Applet程序的下画线处填入代码,使程序完整并能够正确运行。
import java.applet.*;
import java.awt.*;
public class HelloWorld ______ {
public void paint(Graphics g) {
g.drawString("Hello World!",25,25);
}
}
第6题
阅读下面Applet程序 import javax. swing. *; import java. awt. *; public class SwintgApplet extends JApplet{ JLabel 1=new JLabel("This is a Swing Applet."); public void init(){ ________________________________ } } 在程序下画线处填入正确的选项是
A.Container contentPane=getContenPane(); cotentPane. add(1);
B.JPanel comtenPane=new Jpane(); contentPane. add(1);
C.contentPane. add(1);
D.add(1);
第7题
阅读下面Applet程序 import javax. swing. *; import java. awt. *; public class SwintgApplet extends JApplet{ JLabel 1=new JLabel("This is a Swing Applet."); public void init(){ ________________________________ } } 在程序下画线处填入正确的选项是
A.Container contentPane=getContenPane(); cotentPane. add(1);
B.JPanel comtenPane=new Jpane(); contentPane. add(1);
C.contentPane. add(1);
D.add(1);
第8题
下列Applet在坐标(20,20)处显示一幅GIF图像,请填写正确的程序在横线处。 import java.awt.*; import java.applet.*; import java.net.URL; public class Testl3 extends Applet { Image i; public void init() { URL url=getDocumentBase(); String name="IMG nClick=over(this) title=放大0, gif"; 【 】; } public void paint(Graphics g) { g.drawImage(i,20,20,this); } }
第9题
下列是一个Java Applet程序,输出结果是(要求只写出在Applet容器内显示的内容) import java.awt.*; import java.applet.*; public class Testuu extends Applet { float[]x={1.2f,3.4f,5.6f,7.8f}; public void paint(Graphics g) { int s=0; for(int i=0;i〈x.length;i++) s+=(int)x[i]; g.drawstring(" "+s,30,60); } }
A.15
B.16
C.16
D.17
第10题
程序填空题: 制作一个Applet小应用程序,设置其布局为BorderLayout,定义一个按钮和多行文本框并分别放到“North”区域和“Center”区域。 import java.awt.*; import java.applet.*; import javax.swing.*; import java.awt.event.*; //声明AppletDemo类,其父类为JApplet,并实现接口ActionListener (1 ) { JButton btn; JTextArea txt; public void init(){ //设置其布局为BorderLayout (2) btn=new JButton("Show Msg"); txt=new JTextArea(3,20); //把按钮btn放到“North”区域,txt放到“Center”区域 (3) //给按钮注册监听器 (4) } public void actionPerformed(ActionEvent e){ txt.append(btn.getText()); } } 对应的html网页文件为: <applet code=" (5) " width="300" height="200"></applet>
为了保护您的账号安全,请在“上学吧”公众号进行验证,点击“官网服务”-“账号验证”后输入验证码“”完成验证,验证成功后方可继续查看答案!