It's English, my fair cross-dressing sweaty nerd. Go read a book for once in your lifetime. Harry Potter at the very least.
“The best,” replied Severus Snape. -- Harry Potter And The Deathly Hallows, p.1
“The best,” replied Severus Snape. -- Harry Potter And The Deathly Hallows, p.1
You put the punctuation where it makes sense. If it belongs to the quote, it goes inside. If it belongs to the sentence, it goes outside.