One pair of confusing adverbs is 总算 (zǒngsuàn) and 终于 (zhōngyú). They both can be translated as "finally" or "in the end," but they subtly different in tone.

They have the same grammatical structure

Grammatically, 总算 and 终于 are basically used the same way. They are both adverbs, and they can be placed before the subject or after the subject. However, in comparison to 终于, 总算 is seldom used before the subject.

Examples

Nǐ zhōnɡ yú lái le.
你终于来了。
You finally came.

Nǐ zǒnɡ suàn lái le.
你总算来了。
You finally came.

总算 is more informal and impatient

Both 总算 and 终于 express that an action has finally happened after a long wait, however 总算 implies that the speaker had a bit of an agonizing wait, and it has a heavier tone better suited to complaints.

Examples

Zǒnɡ suàn méi chí dào.
总算 没 迟到。
You finally didn't arrive late.

终于 is more formal and objective

终于 is more formal than 总算 (in other words, 总算 is more for spoken Chinese), and it also has a more objective feel (meaning that there was indeed a long wait for this thing that finally happened).

Nǐ zhōnɡ yú jué dìnɡ yào kǎo yán le?
你 终于 决定 要 考研 了?
You finally decided to go to take postgraduate entrance exams?