0

What is the definition of 'empty string' in the lesson ?

Explanation in the lesson is too short for learners that are solo...

11th Feb 2017, 12:16 AM
Didier Baudewyns
Didier Baudewyns - avatar
5 Respostas
+ 4
The better way to learn regex is to practice them: little by little, you will be able to do more things with ;)
11th Feb 2017, 8:54 AM
visph
visph - avatar
+ 2
when there is nothing in the string. myString = "" # empty string using double quotes or myString = '' # empty string using single quotes In regex you'll need to do your regular matching for valid values and then something like using * for 0 or more, or use ? to the pattern optional.
11th Feb 2017, 1:04 AM
ChaoticDawg
ChaoticDawg - avatar
+ 2
@Didier Baudewyns: Forgot "regex" for the moment, as I think you're enough confused as it is ^^ ( and need a complete course to be a minimal learned... Unfortunately, sololearn doesn't provide ones, but fortunaly, you would find a lot of source on internet ) Else @ChaoticDawg is right anyway: an 'empty" string ( of characters ), is a string with zero count of characters, so printing an empty string will output... nothing :P
11th Feb 2017, 4:12 AM
visph
visph - avatar
0
Thank you to both ! I have already used basic regex in notepad++ but I always struggle with these notions of imaginary points, borders and so on, ?! ... so that I don't really exploit the full power of regex. I will indeed go on (elsewhere also!). The first regex lessons here are not bad orherwise...
11th Feb 2017, 8:35 AM
Didier Baudewyns
Didier Baudewyns - avatar
0
Try 'some string (a-z)' then you will see the difference.
11th Feb 2017, 6:50 PM
Asifuzzaman Bappy
Asifuzzaman Bappy - avatar