Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > searching strings

Reply
Thread Tools

searching strings

 
 
Daniel Dalton
Guest
Posts: n/a
 
      03-10-2009
Hi,

I'm writing a program where I search a variable (path), and see if it
contains the whole string of variable name
so:
if name in path:
....
else:
....

One question about this, how can I make it do exactly what it's doing
now, except ignore case? eg. if I do this:
i="A"
j="ab"
i in j
should return true... How do I do this?

Thanks,

Daniel.
 
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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Google search result to be URL-limited when searching site, but notwhen searching Web stumblng.tumblr Javascript 1 02-04-2008 09:01 AM
Strings, Strings and Damned Strings Ben C Programming 14 06-24-2006 05:09 AM
searching strings burchill Java 4 12-07-2004 05:56 AM
searching strings using variables tgiles Python 4 06-15-2004 03:28 PM
Searching and replacing multiple strings in text Chris Java 5 10-11-2003 05:12 AM



Advertisments