import java.applet.*; import java.awt.*; public class caijian extends Applet{ int arrx[] = new int[5]; int arry[] = new int[5]; int i; int xx = 10,yy = 90; int xl = 50,yl=50,xb = 170,yb = 160; public void init() { arrx[0] = 50; arry[0] = 50; arrx[1] = 170; arry[1] = 50; arrx[3] = 50; arry[3] = 160; arrx[2] = 170; arry[2] = 160; arrx[4] = arrx[0]; arry[4] = arry[0]; } public int code(float x, float y) { int c = 0; if(x<xl) c = c|2; else if(x>xb) c = c|2; if(y<yl) c = c|4; else if(y>yb)c = c|8; return c; } public void S_C(Graphics g,float x0,float y0,float x2,float y2) { int c1,c2,c; float x,y,wx,wy; boolean accept = false,done=false; c1 = code(x0,y0); c2 = code(x2,y2); do { if((c1|c2) == 0) { accept = true;