Examples Needed for this question


  • 5
    J

    I am confused why input 1; output shoud be 1 instead of 11;
    Also, input 2, what is the output ?

    More examples would be really helpful for me to understand this question.


  • 0
    J

    the index started from 1, not 0

    if input is 2, the answer should be 11


  • 1
    L

    I guess you're not understand the question. The original string is 1. If input is 1, it means you should return the first level of countAndSay which is the original string 1. Input is the number of level. We count previous level's number and say at current level. Hope my explanation could help you to understand the question.
    1, 1st level
    11, 2nd level
    21, 3rd level
    1211, 4th level
    111221, 5th level
    ...


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.