I have a file which is a list of numbers.

list\_of\_numbers

```
40426
140
26
3502
140
899320

```

and have another file which is a list of numbers to remove **only once**

numers\_to\_remove

```
140
3502

```

so the output file should be

```
40426
26
140
899320

```

Removing only once so 140 is remained as it appears twice in list\_of\_numbers.

Currently I'm doing

```
while read line ; do

    sed -i "0,/^$line$/s///" list_of_numbers

done < numbers_to_remove

```

is there any faster way to do in bash?
I will sort these number after this so the order of numbers are not important.