2
$\begingroup$

I'm trying to make a pattern that looks like this: enter image description here

And am given this code to start:

import static java.lang.System.*;

class TriangleWord
{
private String word;

public TriangleWord()
{
    word = "";
}

public TriangleWord(String w)
{
    setWord(w);
}

public void setWord(String w)
{
    word = w;
}

public String toString()
{

}
}

There's also a runner involved. Please help!!

$\endgroup$
  • 2
    $\begingroup$ This is a programming exercise, so out of scope here. $\endgroup$ – Yuval Filmus Nov 11 '15 at 17:43

Browse other questions tagged or ask your own question.