How can I use the input value as a variable with two arguments?

I already have two inputs. So, I have these two functions that I use within the draw function:

function Re(x, y){
  return x+y;
}

function Im(x, y){
  return x*y;
}

Then I created two inputs

let inpRe;
let inpIm;

function setup(){
  inpRe = createInput('x+y');
  inpIm = createInput('x*y');
}

And I replaced them as follows

function Re(x, y){
  return inpRe.value();
}

function Im(x, y){
  return inpIm.value();
}

with these new values I should be able to plot the same. But it does not work. Am I missing something?

Thanks for your help.