Try this code

```
Sub Test()
Dim a, b, x, ws As Worksheet, sh As Worksheet, i As Long, r As Long
Application.ScreenUpdating = False
Set ws = ThisWorkbook.Worksheets("Raw Data")
Set sh = ThisWorkbook.Worksheets("Output")
sh.Range("A1").CurrentRegion.Offset(1, 1).ClearContents
a = sh.Range("A1").CurrentRegion.Resize(100).Value: r = 2
For i = LBound(a) + 1 To UBound(a)
x = Application.Match(a(i, 1), ws.Columns(1), 0)
If Not IsEmpty(a(i, 1)) Then
If IsError(x) Then
a(i, 2) = "N/A"
a(r, 3) = a(i, 1): r = r + 1
Else
a(i, 2) = ws.Cells(x, 2).Value
End If
End If
Next i
b = ws.Range("A1").CurrentRegion.Value: r = 2
For i = LBound(b) + 1 To UBound(b)
x = Application.Match(b(i, 1), sh.Columns(1), 0)
If IsError(x) Then
a(r, 4) = b(i, 1): r = r + 1
End If
Next i
sh.Range("A1").Resize(UBound(a, 1), UBound(a, 2)).Value = a
Application.ScreenUpdating = True
End Sub
```