I am a rank amateur at this, but I am interested in this topic and tried to make a script to do the job, based on erik's answer. It seems to work, but I worry that I have made some rookie mistake here. Any suggestions? Thank you.
#! /bin/bash
echo "Enter the first directory"
read dir1
echo "Enter the second directory"
read dir2
cd "$dir1"
find | sort > list1.txt
mv list1.txt "$dir2"
cd "$dir2"
find | sort > list2.txt
diff list1.txt list2.txt
rm list1.txt
rm list2.txt
echo "All done"
read -rn1