
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "parser.h"

int * strings_to_ints(int size, char **int_strings) {
  int i;
  int *ints;
  
  ints = calloc(size, sizeof(int));

  for (i=0;i<size;i++) {
    int val;
    sscanf(int_strings[i], "%d", &val);
    /* printf("val: %d\n", val); */
    ints[i]=val;
  }

  return ints;
}

void free_ints(int  *p) {
  free(p);
}
