Dear new user. Your contribution got downvoted. That doesn't mean we think badly of you. Yes, you demonstrated a significant lack of knowledge, but we know that you are still learning and we in no way hold it against you. Have a nice day - we are looking forward to your next contribution. Who knows, maybe you'll get upvoted next time.
Maybe this would be a demonstration of the false dichotomy of quality and kindness. One can ensure quality (up- and downvote) while being kind (using polite language). Still, even like this I guess that downvotes would still be taken personally. It's just a rejection no matter how it is presented. Even as:
We are so sorry, we could not upvote your contribution more. If you tried a little more, maybe...
I wonder though if this would come across as condescending or as trying too hard.
The bottom line I guess is that StackoverflowStack Overflow hinges on voting. It's responsible for all the good and the bad things that happen here.