0

is that any good ideas to fixed the aligment of the output instead of using \t, due to some of the output words have more or less. :)

2
Contributors
3
Replies
4
Views
5 Years
Discussion Span
Last Post by stevanity
0

but i can return method to display it? like use %.2f in C. :)
but i using using return method to display the output

public String toString(){
    	return "\t" + getFlavors() + "\t\t" + getWeight() + "\t\t\t" + getPrice() + "\t\t\t\t" + getQuantity() + "\t\t\t\t" + getPrice() * getQuantity();
    }
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.