@Override
	public String toString(){
		StringBuilder s = new StringBuilder();
		
		for(int i=terms.length; i>0; i--){
			if(terms[(i-1)] == 0)continue;
			if(i!=terms.length){
				if(terms[(i-1)] > 0){
					s.append(" + ");
				} else {
					s.append(" - ");
				}
			}
			if(i-1 == 0){
				s.append(numToString(Math.abs(terms[(i-1)])));
				continue;
			}
			if(i-1 == 1){
				s.append(numToString(Math.abs(terms[(i-1)])) + " * x");
				continue;
			}
			if(terms[(i-1)]==1)s.append("x^"+(i-1));
			s.append(numToString(Math.abs(terms[(i-1)])) + " * x^"+(i-1));
		}
		
		String k = s.toString();
		
		if(k.startsWith(" + "))return k.substring(3);
		
		return k;
	}