Post
Topic
Board Bitcoin Discussion
Re: Bitcoin puzzle transaction ~32 BTC prize to who solves it
by
pbies
on 16/03/2024, 09:24:16 UTC
Hello everyone.

I need a Python script that would check two text files, and if the text in the lines matches, then the script would write “Match found” and write the matching text to a new file. If there is no match, then it would write “No matches found.”

Can anyone help?

Code:
comm -12 <(sort "$1") <(sort "$2")

or

Code:
# command line parameters:
# $1 input: file with patterns to search for
# $2 input: file in which you search for patterns
# $3 output: file to which put found matches

grep -a -Ff "$1" "$2" > "$3"