How semicolons work in English
Every semicolon could be replaced with a period without causing too many problems; you can verify this fact by reading this sentence again and mentally replacing the semicolon with a full stop.
Semicolons are also used in lists with internal punctuation. Uses of the semicolon include separating independent clauses, as in the first paragraph; in lists with internal punctuation, as in this paragraph; and in programming languages such as C, C++, and Java. Note that we couldn't have used exclusively commas in that previous sentence; that would have caused a bit of confusion.