Rectification Notice of CS50: How does (buffer[3] & 0xf0) == 0xe0 work?
I've created the above video because to answer the question of my students. I was doing it in a rush and I've inevitably made a mistake at 0:36 . Below is what I wrote. 0xe0 = 1110 0000 0xe1 = 1110 0001 0xe2 = 1110 0010 0xe3 = 1110 0011 0xe4 = 1110 0100 0xe5 = 1110 0101 0xe6 = 1110 0110 0xe7 = 1110 0111 0xe8 = 1110 1000 0xe9 = 1110 1001 0xea = 1110 1010 0xeb = 1110 1011 0xec = 1110 1100 0xed = 1110 1101 0xef = 1110 1110 I've made a mistake. I've skipped 0xee which is 1110 1110. The correct sequence is as below. 0xe0 = 1110 0000 0xe1 = 1110 0001 0xe2 = 1110 0010 0xe3 = 1110 0011 0xe4 = 1110 0100 0xe5 = 1110 0101 0xe6 = 1110 0110 0xe7 = 1110 0111 0xe8 = 1110 1000 0xe9 = 1110 1001 0xea = 1110 1010 0xeb = 1110 1011 0xec = 1110 1100 0xed = 1110 1101 0xee = 1110 1110 0xef = 1110 1111 I am sorry for my careless mistake and special thanks to Bonnie Tseng for pointing it out.