Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/ExampleArgumentType.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/ExampleArgumentType.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/ExampleArgumentType.cs	(revision 14909)
@@ -9,4 +9,5 @@
     StringVector,
     Char,
+    Print,
   }
 }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Checksum.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Checksum.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Checksum.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = char.MaxValue,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.Char },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Digits.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Digits.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Digits.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = 20,
         InputArgumentTypes = new[] { ExampleArgumentType.Integer },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/DoubleLetters.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/DoubleLetters.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/DoubleLetters.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = 100,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/EvenSquares.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/EvenSquares.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/EvenSquares.cs	(revision 14909)
@@ -19,5 +19,5 @@
         WorstResult = 400,
         InputArgumentTypes = new[] { ExampleArgumentType.Integer },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ForLoopIndex.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ForLoopIndex.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ForLoopIndex.cs	(revision 14909)
@@ -23,5 +23,5 @@
         WorstResult = 1000,
         InputArgumentTypes = new[] { ExampleArgumentType.Integer, ExampleArgumentType.Integer, ExampleArgumentType.Integer },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Grades.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Grades.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Grades.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = 25,
         InputArgumentTypes = new[] { ExampleArgumentType.Integer, ExampleArgumentType.Integer, ExampleArgumentType.Integer, ExampleArgumentType.Integer, ExampleArgumentType.Integer },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 200,
         TestCount = 2000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/PigLatin.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/PigLatin.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/PigLatin.cs	(revision 14909)
@@ -23,5 +23,5 @@
         WorstResult = 100,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 200,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ReplaceSpaceWithNewline.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ReplaceSpaceWithNewline.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ReplaceSpaceWithNewline.cs	(revision 14909)
@@ -23,5 +23,5 @@
         WorstResult = 20,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String, ExampleArgumentType.Integer },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print, ExampleArgumentType.Integer },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ScrabbleScore.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ScrabbleScore.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/ScrabbleScore.cs	(revision 14909)
@@ -1,4 +1,3 @@
 ﻿namespace HeuristicLab.BenchmarkSuite.Problems {
-  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.Char;
   using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.Integer;
   using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.IntegerVector;
@@ -74,5 +73,5 @@
         OutputArgs = output,
         InputString = input,
-        OutputIntegerVector = new[] { ExampleArgumentConverter.ConvertIntegers(output[0]) }
+        OutputInteger = ExampleArgumentConverter.ConvertIntegers(output[0])
       };
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringDifferences.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringDifferences.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringDifferences.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = 100,
         InputArgumentTypes = new[] { ExampleArgumentType.String, ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 200,
         TestCount = 2000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringLengthsBackwards.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringLengthsBackwards.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/StringLengthsBackwards.cs	(revision 14909)
@@ -21,5 +21,5 @@
         WorstResult = 200,
         InputArgumentTypes = new[] { ExampleArgumentType.StringVector },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Syllables.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Syllables.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/Syllables.cs	(revision 14909)
@@ -23,5 +23,5 @@
         WorstResult = 100,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.Integer },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/WordStats.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/WordStats.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/WordStats.cs	(revision 14909)
@@ -24,5 +24,5 @@
         WorstResult = 1000,
         InputArgumentTypes = new[] { ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 100,
         TestCount = 1000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/XWordLines.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/XWordLines.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Problems/XWordLines.cs	(revision 14909)
@@ -22,5 +22,5 @@
         WorstResult = 100,
         InputArgumentTypes = new[] { ExampleArgumentType.Integer, ExampleArgumentType.String },
-        OutputArgumentTypes = new[] { ExampleArgumentType.String },
+        OutputArgumentTypes = new[] { ExampleArgumentType.Print },
         TrainingCount = 150,
         TestCount = 2000,
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Views/ViewHelper.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Views/ViewHelper.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problem.ProgramSynthesis.BenchmarkSuite/Views/ViewHelper.cs	(revision 14909)
@@ -1,11 +1,13 @@
 ﻿namespace HeuristicLab.BenchmarkSuite.Views {
+  using System.Linq;
+
   public static class ViewHelper {
     public static string StringifyInput(ExampleArgumentType type, Example example, string valueSeparator) {
       switch (type) {
         case ExampleArgumentType.Integer: return string.Join(valueSeparator, example.InputInteger);
-        //case ExampleArgumentType.IntegerVector: return string.Join(valueSeparator, example.InputInteger);
+        case ExampleArgumentType.IntegerVector: return "[" + string.Join("], [", example.InputIntegerVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
 
         case ExampleArgumentType.Float: return string.Join(valueSeparator, example.InputFloat);
-        //case ExampleArgumentType.FloatVector: return string.Join(valueSeparator, example.InputFloat);
+        case ExampleArgumentType.FloatVector: return "[" + string.Join("], [", example.InputFloatVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
 
         case ExampleArgumentType.Boolean: return string.Join(valueSeparator, example.InputBoolean);
@@ -13,5 +15,5 @@
 
         case ExampleArgumentType.String: return string.Join(valueSeparator, example.InputString);
-        //case ExampleArgumentType.StringVector: return string.Join(valueSeparator, example.InputString);
+        case ExampleArgumentType.StringVector: return "[" + string.Join("], [", example.InputStringVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
         default: return string.Empty;
       }
@@ -21,8 +23,8 @@
       switch (type) {
         case ExampleArgumentType.Integer: return string.Join(valueSeparator, example.OutputInteger);
-        //case ExampleArgumentType.IntegerVector: return string.Join(valueSeparator, example.OutputIntegerVector);
+        case ExampleArgumentType.IntegerVector: return "[" + string.Join("], [", example.OutputIntegerVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
 
         case ExampleArgumentType.Float: return string.Join(valueSeparator, example.OutputFloat);
-        //case ExampleArgumentType.FloatVector: return string.Join(valueSeparator, example.OutputFloat);
+        case ExampleArgumentType.FloatVector: return "[" + string.Join("], [", example.OutputFloatVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
 
         case ExampleArgumentType.Boolean: return string.Join(valueSeparator, example.OutputBoolean);
@@ -30,5 +32,7 @@
 
         case ExampleArgumentType.String: return string.Join(valueSeparator, example.OutputString);
-        //case ExampleArgumentType.StringVector: return string.Join(valueSeparator, example.OutputString);
+        case ExampleArgumentType.Print: return string.Join(valueSeparator, example.OutputPrint);
+        case ExampleArgumentType.StringVector: return "[" + string.Join("], [", example.OutputStringVector.Select(vector => string.Join(valueSeparator, vector))) + "]";
+
         default: return string.Empty;
       }
@@ -42,4 +46,5 @@
     private const string CharColumnHeader = "char";
     private const string StringColumnHeader = "string";
+    private const string PrintColumnHeader = "print";
     private const string StringsColumnHeader = "string[]";
     public static string GetHeaderTypeName(ExampleArgumentType type) {
@@ -50,4 +55,5 @@
         case ExampleArgumentType.Char: return CharColumnHeader;
         case ExampleArgumentType.String: return StringColumnHeader;
+        case ExampleArgumentType.Print: return PrintColumnHeader;
         case ExampleArgumentType.IntegerVector: return IntegersColumnHeader;
         case ExampleArgumentType.FloatVector: return DoublesColumnHeader;
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Float/FloatConstantErcValue.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Float/FloatConstantErcValue.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Float/FloatConstantErcValue.cs	(revision 14909)
@@ -7,8 +7,10 @@
   public class FloatConstantErcValue : ConstantsWeightedErcValue<double, DoubleArray> {
 
-    public FloatConstantErcValue() : this(new double[0]) { }
+    public FloatConstantErcValue() : this(false, 1d) { }
 
-    public FloatConstantErcValue(params double[] constants)
-      : base(new DoubleArray(constants)) {
+    public FloatConstantErcValue(params double[] constants) : this(true, 1d, constants) { }
+
+    public FloatConstantErcValue(bool isEnabled, double weight = 1d, params double[] constants)
+      : base(isEnabled, new DoubleArray(constants), weight) {
       Name = "Float constants";
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Integer/IntegerConstantErcValue.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Integer/IntegerConstantErcValue.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/Integer/IntegerConstantErcValue.cs	(revision 14909)
@@ -7,8 +7,10 @@
   public class IntegerConstantErcValue : ConstantsWeightedErcValue<int, IntArray> {
 
-    public IntegerConstantErcValue() : this(new int[0]) { }
+    public IntegerConstantErcValue() : this(false, 1d) { }
 
-    public IntegerConstantErcValue(params int[] constants)
-      : base(new IntArray(constants)) {
+    public IntegerConstantErcValue(params int[] constants) : this(true, 1d, constants) { }
+
+    public IntegerConstantErcValue(bool isEnabled, double weight = 1d, params int[] constants)
+      : base(isEnabled, new IntArray(constants), weight) {
       Name = "Integer constants";
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/String/StringRandomErcValue.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/String/StringRandomErcValue.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis.Base/Erc/String/StringRandomErcValue.cs	(revision 14909)
@@ -27,5 +27,5 @@
     private const string NewStringProbabilityParameterDescription = "The probability that the selection of the ephemeral random string constant for inclusion in randomly generated code will produce a new string (rather than a string that was previously generated).";
 
-    public StringRandomErcValue() : base(false, 1d) { }
+    public StringRandomErcValue() : this(false, 1d) { }
 
     public StringRandomErcValue(bool isEnabled, double weight = 1d) : base(isEnabled, weight) {
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Configuration/PushConfiguration.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Configuration/PushConfiguration.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Configuration/PushConfiguration.cs	(revision 14909)
@@ -166,12 +166,15 @@
       EnabledExpressions.Clear();
 
-      // Enable those are required
       foreach (StackTypes type in Enum.GetValues(types.GetType())) {
         if (type == StackTypes.None) continue;
-
         enabledStacks[type] = false;
-
-        if (types.HasFlag(type))
-          EnableStack(type, false, true);
+      }
+
+      foreach (var pair in ExpressionTable.StackDependencyToNamesTable) {
+        if (types.HasFlag(pair.Key)) {
+          foreach (var name in pair.Value) {
+            EnableExpression(name, true);
+          }
+        }
       }
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/ExpressionTable.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/ExpressionTable.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/ExpressionTable.cs	(revision 14909)
@@ -141,5 +141,5 @@
     public static IReadOnlyList<string> GetExpressionsByStackTypes(StackTypes allowedTypes) {
       return stackDependencyToNamesTable
-          .Where(entry => (entry.Key & ~allowedTypes) == StackTypes.None)
+          .Where(entry => (entry.Key & ~allowedTypes) == 0x0)
           .SelectMany(entry => entry.Value)
           .ToArray();
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorNthExpressions.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorNthExpressions.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorNthExpressions.cs	(revision 14909)
@@ -16,5 +16,5 @@
       IPushStack<List<T>> vectorStack,
       IPushStack<T> literalStack) {
-      if (vectorStack.IsEmpty || interpreter.IntegerStack.IsEmpty) return false;
+      if (vectorStack.IsEmpty || vectorStack.Top.Count == 0 || interpreter.IntegerStack.IsEmpty) return false;
 
       var vector = vectorStack.Pop();
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSetExpressions.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSetExpressions.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSetExpressions.cs	(revision 14909)
@@ -17,4 +17,5 @@
       bool isLiteralTypeInteger = false) {
       if (vectorStack.IsEmpty ||
+          vectorStack.Top.Count == 0 ||
           literalStack.IsEmpty ||
           (isLiteralTypeInteger && interpreter.IntegerStack.Count < 2) ||
@@ -38,5 +39,5 @@
 
       if (index < 0)
-        index = vector.Count - index;
+        index *= -1;
 
       vector[index] = literal;
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSubExpressions.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSubExpressions.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorSubExpressions.cs	(revision 14909)
@@ -16,10 +16,13 @@
       if (vectorStack.IsEmpty || interpreter.IntegerStack.Count < 2) return false;
 
-      var first = (int)Math.Min(vectorStack.Count, Math.Max(0, interpreter.IntegerStack[1]));
-      var second = (int)Math.Min(vectorStack.Count, Math.Max(first, interpreter.IntegerStack.Top));
+      var first = (int)Math.Min(vectorStack.Top.Count, Math.Max(0, interpreter.IntegerStack[1]));
+      var second = (int)Math.Min(vectorStack.Top.Count, Math.Max(first, interpreter.IntegerStack.Top));
       interpreter.IntegerStack.Remove(2);
 
+      if (vectorStack.Top.Count == 0)
+        return true;
+
       var result = vectorStack.Top.GetRange(first, second - first);
-      vectorStack.Push(result);
+      vectorStack.SetTop(result);
       return true;
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorTakeExpressions.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorTakeExpressions.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Expressions/VectorTakeExpressions.cs	(revision 14909)
@@ -16,7 +16,16 @@
 
       var count = (int)interpreter.IntegerStack.Pop();
+
+      if (vectorStack.Top.Count == 0)
+        return true;
+
+      count %= vectorStack.Top.Count;
+
+      if (count < 0)
+        count *= -1;
+
       var result = vectorStack.Top.GetRange(0, count);
+      vectorStack.SetTop(result);
 
-      vectorStack.Push(result);
       return true;
     }
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Problem/BenchmarkSuite/PushBenchmarkSuiteEvaluator.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Problem/BenchmarkSuite/PushBenchmarkSuiteEvaluator.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Problem/BenchmarkSuite/PushBenchmarkSuiteEvaluator.cs	(revision 14909)
@@ -2,4 +2,6 @@
   using System;
   using System.Collections.Generic;
+  using System.Linq;
+
   using Common;
   using Core;
@@ -7,5 +9,4 @@
 
   using HeuristicLab.BenchmarkSuite;
-  using HeuristicLab.BenchmarkSuite.Problems;
   using HeuristicLab.Parameters;
   using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
@@ -131,4 +132,9 @@
       interpreter.IntegerStack.Push(example.InputInteger);
       interpreter.FloatStack.Push(example.InputFloat);
+      interpreter.CharStack.Push(example.InputChar);
+      interpreter.StringStack.Push(example.InputString);
+      interpreter.StringVectorStack.Push(example.InputStringVector.Select(v => new List<string>(v)));
+      interpreter.IntegerVectorStack.Push(example.InputIntegerVector.Select(v => new List<long>(v)));
+      interpreter.FloatVectorStack.Push(example.InputFloatVector.Select(v => new List<double>(v)));
 
       interpreter.Run(program);
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/IPushStack.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/IPushStack.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/IPushStack.cs	(revision 14909)
@@ -15,4 +15,5 @@
     void Push(IReadOnlyList<T> items, int startIndex = 0);
     void Push(IReadOnlyList<T> items);
+    void Push(IEnumerable<T> items);
     T Peek();
     T[] Peek(int count);
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/PushStack.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/PushStack.cs	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Problems.ProgramSynthesis/Push/Stack/PushStack.cs	(revision 14909)
@@ -230,4 +230,10 @@
     }
 
+    public void Push(IEnumerable<T> items) {
+      if (!IsEnabled) return;
+
+      data.AddRange(items);
+    }
+
     public void Insert(int index, T item) {
       if (!IsEnabled) return;
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/Erc/ErcTests.cs
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/Erc/ErcTests.cs	(revision 14909)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/Erc/ErcTests.cs	(revision 14909)
@@ -0,0 +1,178 @@
+﻿namespace HeuristicLab.Tests.Erc {
+  using System.Linq;
+
+  using HeuristicLab.Core;
+  using HeuristicLab.Data;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.Char;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.Float;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.FloatVector;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.Integer;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.IntegerVector;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.String;
+  using HeuristicLab.Problems.ProgramSynthesis.Base.Erc.StringVector;
+  using HeuristicLab.Random;
+
+  using Microsoft.VisualStudio.TestTools.UnitTesting;
+
+  [TestClass]
+  public class ErcTests {
+    private const double tolerance = 0.15;
+    private IRandom random;
+
+    [TestInitialize]
+    public void BeforeTest() {
+      random = new MersenneTwister(1337);
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedIntegerErcValueTests() {
+      var options = new IntegerErcOptions(
+                        new IntegerConstantErcValue(true, 0.8, 11, 12, 13),
+                        new IntegerRangeErcValue(true, -10, 10, 0.2));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x <= 10 ? "range" : "constants")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants"] / (double)distribution["range"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedFloatErcValueTests() {
+      var options = new FloatErcOptions(
+                        new FloatConstantErcValue(true, 0.8, 11.1, 12.1, 13.1),
+                        new FloatRangeErcValue(true, -10.5, 10.5, 0.2));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x <= 10.5 ? "range" : "constants")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants"] / (double)distribution["range"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedCharErcValueTests() {
+      var options = new CharErcOptions(
+                        new IntegerConstantErcValue(true, 0.8, 11, 12, 13),
+                        new IntegerRangeErcValue(true, 65, 98, 0.2));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x >= 65 ? "range" : "constants")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants"] / (double)distribution["range"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedStringErcValueTests() {
+      var options = new StringErcOptions(
+        new StringConstantErcValue(true, 0.8, "_1", "_2", "_3"),
+        new StringRandomErcValue(true, 0.2));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x.StartsWith("_") ? "constants" : "random")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants"] / (double)distribution["random"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedIntegerVectorErcValueTests() {
+      var options = new IntegerVectorErcOptions(
+        new IntegerVectorConstantsErcValue(true, 0.8, new[] { 1, 2, 3 }, new[] { 4, 5, 6 }),
+        new IntegerVectorConstantsErcValue(true, 0.2, new[] { 10, 11, 12 }, new[] { 13, 14, 15 }));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x.All(_ => _ < 10) ? "constants1" : "constants2")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants1"] / (double)distribution["constants2"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedFloatVectorErcValueTests() {
+      var options = new FloatVectorErcOptions(
+        new FloatVectorConstantsErcValue(true, 0.8, new[] { 1.0, 2.2, 3.1 }, new[] { 4.1, 5.2, 6.3 }),
+        new FloatVectorConstantsErcValue(true, 0.2, new[] { 10.1, 11.1, 12.2 }, new[] { 13.1, 14.2, 15.3 }));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x.All(_ => _ < 10) ? "constants1" : "constants2")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants1"] / (double)distribution["constants2"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    [TestMethod]
+    [TestProperty("Time", "Short")]
+    [TestCategory("ErcTests")]
+    public void MixedStringVectorErcValueTests() {
+      var options = new StringVectorErcOptions(
+        new StringVectorConstantsErcValue(true, 0.8, new StringArray(new[] { "_1", "_2", "_3" }), new StringArray(new[] { "_4", "_5", "_5" })),
+        new StringVectorConstantsErcValue(true, 0.2, new StringArray(new[] { "-1", "-2", "-3" }), new StringArray(new[] { "-4", "-5", "-5" })));
+
+      Assert.IsTrue(options.IsEnabled);
+
+      var distribution = Enumerable.Range(0, 1000)
+        .Select(_ => options.GetErcValue(random))
+        .GroupBy(x => x.Any(_ => _.StartsWith("_")) ? "constants1" : "constants2")
+        .ToDictionary(group => group.Key, group => group.Count());
+
+      var estimatedRatio = 0.8 / 0.2;
+      var ratio = distribution["constants1"] / (double)distribution["constants2"];
+
+      Assert.IsTrue(IsAlmost(estimatedRatio, ratio, tolerance));
+    }
+
+    private static bool IsAlmost(double x, double y, double tolerance) {
+      return y < x * (1 + tolerance) && y > x * (1 - tolerance);
+    }
+  }
+}
Index: branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/HeuristicLab.Tests.csproj
===================================================================
--- branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/HeuristicLab.Tests.csproj	(revision 14908)
+++ branches/PushGP/HeuristicLab.PushGP/HeuristicLab.Tests/HeuristicLab.Tests.csproj	(revision 14909)
@@ -50,4 +50,8 @@
       <SpecificVersion>False</SpecificVersion>
       <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Core-3.3.dll</HintPath>
+    </Reference>
+    <Reference Include="HeuristicLab.Data-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
+      <SpecificVersion>False</SpecificVersion>
+      <HintPath>..\..\..\..\trunk\sources\bin\HeuristicLab.Data-3.3.dll</HintPath>
     </Reference>
     <Reference Include="HeuristicLab.Problems.Instances-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL">
