public static int createPropositionalTrainingExamples(List examples, OutputFileStream nameFile, OutputFileStream dataFile) {
    { int numInputs = 0;
      Module home = ((Module)(Stella.$MODULE$.get()));
      int temp = 0;
      Vector input = null;

      { TrainingExample example = null;
        Cons iter000 = examples.theConsList;

        for (;!(iter000 == Stella.NIL); iter000 = iter000.rest) {
          example = ((TrainingExample)(iter000.value));
          if (!(example.module == null)) {
            example.module.changeModule();
          }
          input = Logic.createInputSignature(example.query);
          example.input = input;
          home.changeModule();
          { IntegerWrapper ele = null;
            Vector vector000 = input;
            int index000 = 0;
            int length000 = vector000.length();

            for (;index000 < length000; index000 = index000 + 1) {
              ele = ((IntegerWrapper)((vector000.theArray)[index000]));
              temp = ele.wrapperValue;
              dataFile.nativeStream.print(temp + ",");
            }
          }
          dataFile.nativeStream.println(example.output);
        }
      }
      numInputs = input.length();
      nameFile.nativeStream.println("true,false");
      { int i = Stella.NULL_INTEGER;
        int iter001 = 0;
        int upperBound000 = numInputs - 1;

        for (;iter001 <= upperBound000; iter001 = iter001 + 1) {
          i = iter001;
          nameFile.nativeStream.println("A" + Native.stringify(IntegerWrapper.wrapInteger(i)) + ":  1,0");
        }
      }
      return (numInputs);
    }
  }