diff --git a/lec40_git/Diamond.java b/lec40_git/Diamond.java new file mode 100644 index 0000000..3edffe0 --- /dev/null +++ b/lec40_git/Diamond.java @@ -0,0 +1,14 @@ +import java.awt.Color; + +public class Diamond implements PartyShape { + public void draw(Turtle t) { + t.setColor(Color.GREEN); + // Draw a diamond using primitive turtle moves + for (int i = 0; i < 2; i++) { + t.forward(60); + t.turnRight(110); + t.forward(60); + t.turnRight(70); + } + } +} \ No newline at end of file