• This was a good question. I gave wrong answer or better to say incomplete answer (opted for only 4). Method 2 I was not sure because of code written was not complete.

    from my perspective, losing 2 points is not a big deal than gaining small but important piece of knowledge.