in reply to Re^6: Algorithm for cancelling common factors between two lists of multiplicands
in thread Algorithm for cancelling common factors between two lists of multiplicands

The pattern (_:_) will not match an empty list [], so the first definition will match only when both input lists are non-empty. If one or both of the inputs are empty, the second definition will match.
  • Comment on Re^7: Algorithm for cancelling common factors between two lists of multiplicands