CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Regular Expressions:
Set time in the file

 



swaugh
New User

Sep 4, 2010, 4:24 AM

Post #1 of 2 (2140 views)
Set time in the file Can't Post

Hi All,

I am searching regular expression for below problem.

I have a large input file, contains lines of this sort

00:02:58,262 --> 00:03:01,473
00:03:05,561 --> 00:03:07,771

ie. hh:mm:ss,no --> hh:mm:ss,no

Problem is here, there is a time difference so I need to set these times in another file.

Let say for the above example there is a time difference of 3 sec so the output should be
00:03:01,262 --> 00:03:03,473
00:03:08,561 --> 00:03:10,771

Could you please help me or any pointers will be helpful..

Thanks in advance.


FishMonger
Veteran / Moderator

Sep 4, 2010, 7:17 AM

Post #2 of 2 (2133 views)
Re: [swaugh] Set time in the file [In reply to] Can't Post

Take a look at the Add_Delta_DHMS() function in Date::Calc

http://search.cpan.org/~stbey/Date-Calc-6.3/lib/Date/Calc.pod

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives