@Override
	public Object evaluate(ArrayList<Context1> pila) throws Exception {
		inicio.evaluate(pila);
		pila.add(new Context1());
		String variable = ((DeclaracionEvaluator) (inicio)).getNombre();
		TermEvaluator termino = new TermEvaluator(variable);
		StringBuilder output = new StringBuilder();
		int conta = 0;
		while ((Boolean) condicion.evaluate(pila) == true) {
			conta ++;
			//This is to avoid infinite loops.
			if(conta > 100000){
				conta = 0;
				if(stopLoop())
					break;
			}
			pila.add(new Context1());
			for (Evaluator e : lista) {
				if (e != null) {
					Object retorno = e.evaluate(pila);

					if (retorno != null) {
						if (retorno instanceof Double)
							output.append(((Double) retorno).toString());
						else
							output.append(retorno.toString());
					}
				}
			}
			pila.remove(pila.size() - 1);
			if(incremento instanceof DoubleEvaluator){
				AsignacionEvaluator asignacion = new AsignacionEvaluator(variable,
						new DoubleEvaluator((Double) termino.evaluate(pila)
								+ (Double) incremento.evaluate(pila)));
				asignacion.evaluate(pila);
			}else{
				System.out.println("entre al else del incremento");
				incremento.evaluate(pila);
			}
		}
		pila.remove(pila.size() - 1);
		return output.toString();


	}