I
I
Ilgiz Khamitov2015-02-16 18:05:24
*nix-like systems
Ilgiz Khamitov, 2015-02-16 18:05:24

How to remove lines from a file that are in another file quickly!?

How to remove lines from a file that are in another file quickly!?
The files are large in volume, each term has a unique value. Example:

1
2
3
5
120
144

Answer the question

In order to leave comments, you need to log in

1 answer(s)
J
jcmvbkbc, 2015-02-16
@jcmvbkbc

Does the order of lines in a source file matter?
If not, then you can do this:
comm -2 -3 <(sort file1) <(sort file2) > file1-file2

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question