Need Help comparing dates
John Machin
sjmachin at lexicon.net
Fri Jun 16 20:32:32 EDT 2006
On 17/06/2006 9:55 AM, colincolehour at gmail.com wrote:
> So when I grab the date of the website, that date is actually a string?
Yes. Anything you grab off a website (or read from a file) will be held
in a string. Typically you would then need to convert it (or parts of
it) to some other type(s) e.g. int, float, date, ...
>
> How would I got about converting that to a date?
By following the instructions you have already been given. The response
by Tim Chase gives you a stir-by-stir recipe.
===
You said "I am new to Python and am working on my first program". Here
are some diagnostic questions the answers to which should enable us to
prescribe some more help for you: In what other computer language(s)
have you written programs? What book or tutorial are you using to learn
Python? Have you worked through the book/tutorial's examples/exercises
before starting "my first program"?
Cheers,
John
More information about the Python-list
mailing list