I really enjoyed the INTRODUCTION TO BITWISE OPERATORS up until Slip and Slide:
When I read the instructions I was very confused as to what was expected. I got the correct code and I understand it without a problem. To be honest, I got the correct code after giving up because I was simply not understanding the question at all but I knew I would be able to interpret the correct code.
While studying the answer I did learn something new; that
0b1 << (n -1) can return a result, which is cool and an imperative to solve the problem.
Below is an excerpt from the instructions. The bold text, specifically the section that is emphasized confused me:
‘Flip the nth bit (with the ones bit being the first bit) and store it in result.’
Could someone rephrase the instructions in a way that is…clearer or less ambigous to someone who speaks English as a third language? I would really appreciate it.