1113. Compound Sentence or not?

Use a comma before the word and and the word but when joining two simple sentences to make a compound sentence.
I’m hungry, but we have nothing to eat.
It’s raining, but the sun may shine later.
Janice is my friend, and she is also my sister.

Not every sentence with the word but or the word and needs a comma. Sometimes we use these words when they aren’t part of a compound sentence. Look at these sentence examples that do not need a comma:
That shot with the basketball hit nothing but net.
I ate some cereal and a banana this morning.
Three cats and a dog ran through our yard.

Only use a comma with the word and and the word but when the conjunction joins two complete thoughts to make a compound sentence.

It’s your turn. Decide if you should place a comma into this sentence: It’s hot today but tomorrow will be cooler. Did you put a comma before but? Good for you!