Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Regd. Kodos

Reply
Thread Tools

Regd. Kodos

 
 
vishal@veriwave.com
Guest
Posts: n/a
 
      02-03-2007
I am trying to use Kodos..but not getting thru'..dont know whats goin
on..does anyone have a regular expression for time in hh:mm:ss
-Vishal
 
Reply With Quote
 
 
 
 
Paddy
Guest
Posts: n/a
 
      02-03-2007
On Feb 3, 8:59 am, (E-Mail Removed) wrote:
> I am trying to use Kodos..but not getting thru'..dont know whats goin
> on..does anyone have a regular expression for time in hh:mm:ss
> -Vishal


Well, with just knowing the above, the following raw string when used
as a regular expression will capture the hh,mm,ss as groups 1,2,3
r'\b(\d\d)\d\d)\d\d)\b'

- Paddy

 
Reply With Quote
 
 
 
 
Paddy
Guest
Posts: n/a
 
      02-03-2007
On Feb 3, 9:17 am, "Paddy" <(E-Mail Removed)> wrote:
> On Feb 3, 8:59 am, (E-Mail Removed) wrote:
>
> > I am trying to use Kodos..but not getting thru'..dont know whats goin
> > on..does anyone have a regular expression for time in hh:mm:ss
> > -Vishal

>
> Well, with just knowing the above, the following raw string when used
> as a regular expression will capture the hh,mm,ss as groups 1,2,3
> r'\b(\d\d)\d\d)\d\d)\b'
>
> - Paddy


P.S. I fired up Kodos and cut and pasted your message into the search
string box;
left the bottom notebook on the groups tag to show what groups i had
captured; left the flags al off; then started typing the regular
expression into the regular expression pattern box.
Thats when i realised that your email said hh:mm:ss and I needed to
match something with numbers so appended 08:34:66 as a new ine in the
search string box.
After typing in the regex, the group tab showed what I was after

I like Kodos because it helps me when the RE's are much longer but i
have sample text that I can easily paste in. I usually paste in a
large tet sample just to make sure my RE doesn't fail on something I'm
not expecting.
- Paddy.
..

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off




Advertisments