code: function getUnion(p1, p2) {
    var i = 0;
    var max = Math.min(p1.length, p2.length);
    while(p1[i] === p2[i] && i < max) {
      i++;
    }
  
    return p1.substring(0, i);
  }
docs: /*\
  |*| Gets the longest shared prefix of two strings.
  \