Write a method for Turtle to draw an equilateral triangle. Pass in the length of the sides.

What will be an ideal response?


```
public void drawEquilateralTriangle (int width)
{
this . turn ( 30 ) ;
this . forward ( width ) ;
this . turn ( 120 ) ;
this . forward ( width ) ;
this . turn ( 120 ) ;
this . forward ( width ) ;
this . turn ( 90 ) ;
}
```

Computer Science & Information Technology

You might also like to view...

Structured programming is commonly called "spaghetti code."

Answer the following statement true (T) or false (F)

Computer Science & Information Technology

____ speed is measured in hertz.?

A. ?Clock B. ?Printer C. ?Word D. ?Swap file

Computer Science & Information Technology

A Windows stop error is better known as the _______________.

A. Windows Recovery Screen B. Windows Panic Screen C. Blue Screen of Death D. Black Screen of Death

Computer Science & Information Technology

A Hyper-V function that allows for memory to be pooled within a host. As VMs require more memory, Hyper-V allocates additional memory by taking it form an underutilized or overcommitted VM.

1. Dynamic Memory
2. Enhanced Session Mode
3. Guest
4. Guest Integration Services
5. Host (Hyper-V)
6. Hyper-V
7. Hypervisor
8. Smart Paging
9. Resource Metering
10. Private Network

Computer Science & Information Technology