I thought regular expression was greedy in pattern matching(in java it is ) $String = "Rama and Sham are honest9"; $String =~ /(\w+$)/; print $1; This is the code i ran it came out as honest9 you explanation says it "9t" i couldn't get adding an integer to increasing the ascii value of the string either? $a = "one"; $b = $a+1; (or) $b = ($a+1); or printing it in " " or ' ' any combination didn't work its always returning "1"
The thing I hate the most about writing Perl scripts is waiting for them to finish the task I've given them. Be direct, but is this the way of scripting, my own control flow, or the language? There is nothing more frustrating than trying to nail the right regular expression.
Great tool for watching long lectures on youtube, speed up and save time. Click my profile for link to download MySpeed Plug-In for YouTube and Speed up or Slow down any YouTube Video. Watch a 60 minute lecture in just 30 minutes and understand everything.
Pretty good overall. The first non-regex example had a bug (the every and body should be separated by a space for the match to work). The discussion of the *,+ and ? was a bit confusing. I thought these were quantifiers for whatever immediately preceded them.. \d+ is one or more digits etc. and \d{2} is exactly 2 repetitions whereas the discussion did not make the association clear (it suggested these were repetitions of general characters).
no sound come please do something
dksingh024 1 week ago
I cont hear voice from this video... Can you correct it ?
jeevantpt22 5 months ago
I cont hear voice from this video... Can you correct it ?
jeevantpt22 5 months ago
This has been flagged as spam show
I cont hear voice from this video... Can you correct it ?
jeevantpt22 5 months ago
This has been flagged as spam show
I cont hear voice from this video... Can you correct it ?\
jeevantpt22 5 months ago
This has been flagged as spam show
I cont hear voice from this video... Can you correct it ?
jeevantpt22 5 months ago
I cont hear voice from this video... Can you correct it ?
jeevantpt22 5 months ago
I was right. IITs are overrated. I can't believe an IIT professor can be wrong. (about REGEX in this video - in Ram and Shyam examples).
ramani86 8 months ago
print "$1 $2\n";this will print out Ram and
arunanirudhan 1 year ago 2
$s=~/^(\w+)\s+(\w+)/;
arunanirudhan 1 year ago 2
$s=~/(\w+)$/;
Sir, this will print out honest
arunanirudhan 1 year ago 2
my $str="Ram and shyam are honest";
$str=~/^(\w+)/;
print "$1\n";
Sir, this will print out Ram
arunanirudhan 1 year ago 4
@arunanirudhan yes it will print only the first word, you can change the regex as /^(\w+\s+\w+)$/ , it will print the full line.
skmarwat 3 months ago
@skmarwat OR /^(\w\s)+$/ i think this will also work, i havnt test it right now but it will.
skmarwat 3 months ago
The teacher lacks the basic concept of perl... Perl is GREEDY in nature. His examples are wrong, pl don't listen to this video.
arunanirudhan 1 year ago
@arunanirudhan : you need to correct your concepts ... regex(s) are greedy and not perl ... does that make sence !!!
shayansinha87 7 months ago
i can not hear voice in this lecture ... can you please update the video again. Thanks
resonatingvoice 1 year ago
laudavarun 2 years ago
fail at 1:24!
LOL....
Practical Reporting and Extraction Language...
that would make PREL :P
timtico 2 years ago
@timtico Fuck u!
ABHAY1475 1 year ago
The thing I hate the most about writing Perl scripts is waiting for them to finish the task I've given them. Be direct, but is this the way of scripting, my own control flow, or the language? There is nothing more frustrating than trying to nail the right regular expression.
srflaxu40 2 years ago
awesome, just what I was looking for, more information of search regexp.
wackypro 3 years ago
This has been flagged as spam show
^
|
Great tool for watching long lectures on youtube, speed up and save time. Click my profile for link to download MySpeed Plug-In for YouTube and Speed up or Slow down any YouTube Video. Watch a 60 minute lecture in just 30 minutes and understand everything.
enounce 3 years ago
Pretty good overall. The first non-regex example had a bug (the every and body should be separated by a space for the match to work). The discussion of the *,+ and ? was a bit confusing. I thought these were quantifiers for whatever immediately preceded them.. \d+ is one or more digits etc. and \d{2} is exactly 2 repetitions whereas the discussion did not make the association clear (it suggested these were repetitions of general characters).
srinsriram 3 years ago