N5
は
As for... (Highlights sentence topic)
田中さんは先生です。
Tanaka-san is a teacher.
Explanation
「は」 has 2 uses
1The topic
Puts the person or thing you are talking about first, then says something about it. 「私は学生です」 is "As for me, I am a student."
私はトムです。
I am Tom.
田中さんは先生です。
Tanaka-san is a teacher.
2Contrast
Sets one thing against another, or hints that other things may be different: 「肉は食べます」 (Meat, I do eat).
私は、金曜日は好き。
Fridays I do like.
兄はいますが、姉はいません。
I have an older brother, but no older sister.
Mixed up with
「は」 = 'speaking of X', with the weight on what follows; 「が」 = 'it is X, nobody else', with the weight on X. 「私が田中です」 answers 'Who is Tanaka?'; 「私は田中です」 is a self-introduction.
A question word as subject takes 「が」, and so does the answer: 「誰が来ましたか」 / 「田中さんが来ました」.
「象は鼻が長い」: the whole (the elephant) takes 「は」, the part (the trunk) takes 「が」.
Inside a clause that modifies a noun, such as 「私が買った本」, the subject takes 「が」, not 「は」.