Class InvertedTriangle

java.lang.Object
  extended by InvertedTriangle

public class InvertedTriangle
extends Object

This class describes inverted triangle objects that can be displayed using asterisks and new lines


Constructor Summary
InvertedTriangle(int aWidth)
          Constructs an inverted triangle.
 
Method Summary
 String toString()
          Computes a string representing the inverted triangle.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InvertedTriangle

public InvertedTriangle(int aWidth)
Constructs an inverted triangle.

Parameters:
aWidth - the number of * in the first row of the triangle.
Method Detail

toString

public String toString()
Computes a string representing the inverted triangle.

Overrides:
toString in class Object
Returns:
a string consisting of * and newline characters