In American English, place commas and periods inside the closing quotation mark (unlike British English).
This practice came from a time when type was set by hand. The delicate period and comma outside of quotation marks at the end of a sentence tended to get knocked out of place, bruised, or broken; so, printers ended up placed them inside the quotation marks to solve this problem. The practice has not changed, even though broken type is no longer an issue in print.
So, take note:
Period—The students gathered in the field to “observe the lay of the land.”
Comma—“The baby fell asleep,” the nurse whispered.
Set quotation marks before semicolons and colons
At first, Madge said she was “afraid to jump”; by the end of the class she had changed her mind.
“Inertia is defined as follows”: … Madge wrote, before she heard screams coming from the other room.
Set quotation marks before exclamation points and question marks that are not part of the quotation.
“Stop complaining!” she shouted.
“Is he going to complain again?” Madge whispered.
Use single quotation marks for a quote within a quote (the opposite is done in British English).
“Stop complaining” said Madge. “Remember that ‘the early bird catches the
worm’ and be glad you have to wake up at dawn.”
For help in putting your best forward in your work, contact me at email@example.com. See my work at editsbymarks.com and peruse the articles on this blog.