During the American Civil War, how many states fought for the Union; and how many for the Confederacy?

History Trivia Question: During the American Civil War, how many states fought for the Union; and how many for the Confederacy?