There are several methods but here's something simple..

Load each file into an array - look at the FileIO UDF -
 Code:
$Array = FileIO('filename', 'R')
Call this once for each file, using different names for the $Array variable ($aNeed and $aHave, for example) and source filename.

Enumerate the "have" array, locate the matching record in the Need array and clear that value.
 Code:
For Each $Patch in $aHave
  $E = AScan($aNeed, $Patch) ; look for the current patch in the NEED array
  If $E >= 0           ; will be -1 if not found
    $aNeed[$E] = ''    ; clear the value from the NEED array
  EndIf
Next
The $aNeed array will contain only the missing patches.

Optionally, use the QS or QSort UDF to sort the array. Save the resulting array.
 Code:
$aNeed = QSort($aNeed) ; sort
$ = FileIO(@WSKTA + '_Need.txt', 'W', $aNeed, 2)
The option "2" on FileIO will strip the blank lines. This will create a computer-specific file containing the patches that are needed.

Glenn

PS - all of the UDFs I referenced can be found in the Kix UDF Library on my web site - link in sig. Most are here on KORG, but may be outdated.
_________________________
Actually I am a Rocket Scientist! \:D