two steps 发表于 2003-7-21 14:47

好啊, hören wir auf...:-)
我也是刚开始学的....你那个名字好有意思啊, 让我想起了我们一个tutor....他的口头语好象就是什么zik zak....;p

ZICK 发表于 2003-7-21 14:53

你在哪里上学啊,学info的吗,第几学期,真的好厉害啊.肯定以前c学的很好

two steps 发表于 2003-7-21 15:08

呵呵, 你说的我脸都红了....也加上天热ing.... O-)

aachen , info第二学期   

"肯定以前c学的很好"faint....倒ing....偶家只有java的书...都是到德国后听说这里是学java后现买的......

ZICK 发表于 2003-7-21 21:49

不好意思,我又回来了...

public class RectangleDemo
{
        public static void main(String args[])
        {
                Point p1;
                Rectangle r1 = new Rectangle(p1,40,30);               
                r1.move(50,50);
                System.out.println("Der Flaecheninhalt des Rechtecks ist " + r1.area());
        }
}

class Rectangle
{
        Point origin;
        int width, height;
        int area()
        {
      return(width*height);
   }
}

class Point
{
        int x,y;
        Point(int xCoord,int yCoord)
        {
      x = xCoord;
      y = yCoord;
   }                     
}

RectangleDemo.java:6: cannot resolve symbol
symbol: constructor Rectangle(Point,int,int)
location: class Rectangle
                Rectangle r1 = new Rectangle(p1,40,30);               
                               ^
RectangleDemo.java:7: cannot resolve symbol
symbol: method move(int,int)
location: class Rectangle
                r1.move(50,50);
                  ^
2 errors
Exit code: 1
There were errors

two steps 发表于 2003-7-21 22:04

RectangleDemo.java:6: cannot resolve symbol
symbol : constructor Rectangle (Point,int,int)//class Rectangle没有型如(Point, int, int ) 的konstruktor,
location: class Rectangle
Rectangle r1 = new Rectangle(p1,40,30);//而main里边却来了个对r1的initialisierung.

^
RectangleDemo.java:7: cannot resolve symbol
symbol : method move (int,int)
location: class Rectangle
r1.move(50,50);
^
同样, 里只有一个求面积的methode, 而没有这个move ( int , int) methode ...编译时找不找呀.

aaaabbbb 发表于 2003-8-11 14:44

同事同事
页: 1 2 [3]
查看完整版本: [求助]刚开始学,一头雾水...