[Tutor] Copy Files, Dates

Bob Gailer bgailer@alum.rpi.edu
Fri Apr 18 18:44:03 2003


--=======6DBD7463=======
Content-Type: text/plain; x-avg-checked=avg-ok-5B0351B2; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 8bit

At 03:55 PM 4/18/2003 -0600, Mike Hansen wrote:
>[snip]
>How do you copy files using Python?

Check out the shutil module

>First I need to find out if a string is a Date. Is there any IsDate like 
>function? Also, is there a module that compares dates?

Unfortunately there is no standard format for dates. To ask if a string is 
a date is very vague. Do you have certain formats in mind? Check out the 
time module. There is a strptime function which takes a string and a 
format. You'd probably have to try several formats.

Bob Gailer
bgailer@alum.rpi.edu
303 442 2625

--=======6DBD7463=======
Content-Type: text/plain; charset=us-ascii; x-avg=cert; x-avg-checked=avg-ok-5B0351B2
Content-Disposition: inline


---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.467 / Virus Database: 266 - Release Date: 4/1/2003

--=======6DBD7463=======--