how does star work in combinatronics?

45 Views Asked by At

how does work in binary strings?

(0*1)*0*

like what does it concatenate to? I'm having a difficult time understanding it as there are very few resources on the topic can some one explain this to me?

1

There are 1 best solutions below

0
On

$0^*$ simply means a string of zeroes of any length, including none at all: it describes the empty string and the strings $0,00,000,0000$, and so on. Thus, $0^*1$ describes all strings that consist of a $1$ preceded by any number of zeroes, including none at all: $1,01,001,0001,$ and so on.

$(0^*1)^*$ then describes any string that you can get by concatenating strings of the type that I just described. You might have just one of them: $1,01,001,0001$, and so on. You might have two of them: $11,101,011,1001,01001,001001000101$, and so on. Or you might have three of them, or four, or any finite number, and each could have a different number of zeroes.

Finally, $(0^*1)^*0^*$ lets you follow any of the strings described in the preceding paragraph with any number of zeroes. If you think about it for a bit, you should be able to see that any string of zeroes and ones whatsoever fits this description.