Commit 984d6be4 authored by gu-jinli1118's avatar gu-jinli1118
Browse files

55

parent 4e59babb
...@@ -4,6 +4,6 @@ public class triangle extends shape { ...@@ -4,6 +4,6 @@ public class triangle extends shape {
@Override @Override
public double area(int length,int width) { public double area(int length,int width) {
System.out.println ("triangle ~area"); System.out.println ("triangle ~area");
return 1/2*length*width; return 1.0/2*length*width;
} }
} }
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment