Probably not.
Three Hearts and Three Lions was first published in novella form in 1953, prior to the publication of Lord of the Rings.
Now, you might think that maybe Anderson got it from The Hobbit ... but while it was published in 1937, and it was a decent success, it was marketed as a children's book and wasn't the smash success we think of today. It wasn't until after LOTR and, especially, the 60s that the cult of Tolkien really started.
So... maybe, but probably not. Unless someone knows more about Anderson's reading habits in the early 50s.
ETA- ninja'd by Cadence.