unix How to compare two files and get results to third file?

Posted by Martin Mocik on Stack Overflow See other posts from Stack Overflow or by Martin Mocik
Published on 2012-05-31T10:10:01Z Indexed on 2012/05/31 10:41 UTC
Read the original article Hit count: 242

Filed under:
|
|
|
|

I have two files

1st file is like this:

www.example.com
www.domain.com
www.otherexample.com
www.other-domain.com
www.other-example.com
www.exa-ample.com

2nd file is like this (numbers after ;;; are between 0-10):

www.example.com;;;2
www.domain.com;;;5
www.other-domain;;;0
www.exa-ample.com;;;4

and i want compare these two files and output to third file like this:

www.otherexample.com
www.other-example.com

Both files have large size (over 500mb)

© Stack Overflow or respective owner

Related posts about linux

Related posts about bash