Simplest solution (that works for large data samples, rather than just the tiny ones you have there) is easy: Sort the two arrays.
Now each array is in order and a simple loop will enable you to see what is different.
Think about it:
A1) [W A M G B] => [A B G M W]
A2) [O K A W] => [A K O W]
If you compare element 0 of A1 with element 0 of A2, then it's obvious A is duplicated - so move both indexes.
Compare element 1 of A1 with element 1 of A2 and it's obvious that B is unique - so move A1 index only
Compare element 2 of A1 with element 1 of A2 and it's obvious that G is unique - so move A1 index only
Compare element 3 of A1 with element 1 of A2 and it's obvious that K is unique - so move A2 index only
And so on until you run out of one array or the other, in which case all the rest of the items are unique.
Try it on paper and you'll see what I mean. .
If you are having problems getting started at all, then this may help:
How to Write Code to Solve a Problem, A Beginner's Guide[
^]