Also take a look at the syntax of the for statement and notice it has an
else clause.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
://en.wikipedia.org/wiki/Python_Pipelines for a brief description.
Let me know if you want to know more.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
ot evaluate
thing? How can it take it as a literal string without quotes?
I suggest you look dict up in the Python documentation. There it shows
the result you got as an example. When in doubt read the manual.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
al to {"one": 2, "two": 3}:
...
dict( two=3)
From: bob
gailer
To: wormwood_3
Cc: Python Tutorlist
Sent: Wednesday,
January 21, 2009 11:02:35 PM
Subject: Re: [Tutor]
dict() versus {}
wormwood_3 wrote:
When
creating a list of dictionaries thr
jadrifter wrote:
On Wed, 2009-01-21 at 22:53 -0500, bob gailer wrote:
Eric Dorsey wrote:
Does anyone know of any good volunteer opportunities for projects that
learning Python coders can work on? Or possibly nonprofits or the like
that need smaller-type
with python?
Yes - and also possible with almost all other programming languages.
Here is one of several ways to do it in Python:
for first_name in ('Bob', 'John', 'Joe', 'Jim', 'Fred'):
if first_name in text:
print first_name, 'found'
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
+ to act as or
self._value |= other
def __mul__(self, other): # causes * to act as and
self._value &= other
b = Bit(1)
b.value # returns 1
b.value = 0
b.value # returns 0
b.value + 1 # sets value to 1
b.value * 0 # sets value to 0
--
Bob Gailer
Chapel Hill NC
919-636-4239
__
Vicent wrote:
On Sat, Jan 24, 2009 at 19:48, bob gailer <bgai...@gmail.com>
wrote:
The problem is: there is no
way that I know of to add fundamental types
to Python. Also realize that variables are dynamically typed - so any
assignment can create a variable of a ne
results.
If the program raises an exception, post the entire traceback.
If something else, explain that.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
t "The guess is", loops, "which is", loops -
math.sqrt(x),"away from", math.sqrt(x)
main()
^Do you have any suggestions as to what I should do?
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@pytho
works with 2003 Server.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Lie Ryan wrote:
[snip]
AFAIK no CPU implements hardware logical operation).
I disagree. But perhaps logical operation means different things to you.
Please expand.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor
s that of main(), but the
call to f() is nested in main(); it does not "jump out".
Also: does Python go back to the function call main()'s position after
step 3)?
Yes. when f() is called the position in main() is placed on a "stack".
When f() returns, the position of
1, https://www.localhost.org/
2. testmodule
3. /dev/trunk/admin/sql/mytest.sql
Thanks,
Jay
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
ing" applies to this question.
The obvious answer is:
print("1, https://www.localhost.org/"";
print()
print("2. testmodule")
print()
print("3. /dev/trunk/admin/sql/mytest.sql")
If that is not what you are looking fo
. Much clearer.
header = "https://www.localhost.org/";
test = "https://www.localhost.org/foo/bar"; # we desire to extract 'foo'
start = len(header)
end = test[start:].find('/') + start
result = test[start: end]
print res
a repeatable set of numbers at some
point? I'm trying to understand the periodicity (or lack of) of the
numbers generated by rand.randint()
random uses AFAIK the Mersenne Twister algorithm. See
http://en.wikipedia.org/wiki/Mersenne_twister
--
Bob Gailer
Chapel Hill NC
919-636
>>> struct.calcsize('s')
1
>>> struct.calcsize('d')
8
>>> struct.calcsize('sd')
16
Why? Should not that be 9?
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
s and report back your results. And also the FORTRAN
variable types if you have access to them.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
("2s8s2si2s1s")
items = struct.unpack("2s8s2si2s1s",data[start:stop])
print items
print data[:40]
I'm pretty sure that when I tried this at the other PC there were a
bunch of \x00\x00 characters in the file but they don't appear in
NotePad ... any
W W wrote:
On Tue, Feb 3, 2009 at 6:25 PM, bob gailer <mailto:bgai...@gmail.com>> wrote:
>>> struct.calcsize('s')
1
>>> struct.calcsize('d')
8
>>> struct.calcsize('sd')
16
Why? Should not that be
.
At 21:41 03/02/2009, bob gailer wrote:
First question: are you trying to work with the file written
UNFORMATTED? If so read on.
Well, did you read on? What reactions do you have?
eShopping wrote:
Data format:
TIME 1 F 0.0
DISTANCE 10 F 0.0 1.0 2.0 3.0 4.0 5.0 6.0 7.0 8.0 9.0
F=
>>> x=open('x','w') # write "normal" allowing \n to be translated to
the OS line end.
>>> x.write("Hello\n")
>>> x=open('x','rb') # read binary, avoiding translation.
>>> x.read()
'Hello\r\n'
where \r = \x0d
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Okeke emmanuel wrote:
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
At least the subject is accurate!
--
Bob Gailer
Chapel Hill NC
://en.wikipedia.org/wiki/Python_Pipelines
Thank you for the plug! The code is currently in flux so not available.
I hope to have an alpha version out soon.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http
quot;finalizing".
Assistants are always welcome.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
- there is no need to multiply remprod by the remainders as you don't
use that result later.
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
correct?
--
Bob Gailer
Chapel Hill NC
919-636-4239
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
n the principal. "
balance = principal + interest
print balance, "is the new principal. "
count = count + 1
if tuition > principal:
print principal + interest, "was available for the last student."
if count > 10:
print count, "Students used this grant."
-
Thanks again,
Pat
On Feb 8, 2009, at 3:11 PM, bob gailer wrote:
principal = balance = 50 # Starting fund amount.
interestRate = .05 # Interest rate added to the principal annually.
tuition = 34986 # Starting tuition fee
tuitionInc = 1.041 # The annual increase applied to the tuition.
etrade.griffi...@dsl.pipex.com wrote:
Hi
following last week's discussion with Bob Gailer about reading unformatted FORTRAN files, I have attached an example of the file in ASCII format and the equivalent unformatted version.
Thank you. It is good to have real data to work with.
Bel
Above you show some "combinations" and a subset of the permutations.
What rules did you apply to come up with your result?
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscr
n I find:
"All non-keyword arguments are converted to strings like str() does"
Under str() I find:
"returns its nicely printable representation."
OK but still kinda vague.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tut
s?
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tut
I agree. What do we do to fix the "problem"?
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
whether it makes sense (or is even possible) to use vim in
Windows (I use Windows XP-SP3).
FWIW I started 10 years ago using Python For Windows as my development
environment. I have never regretted that choice.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
On 12/22/2010 7:31 AM, Steven D'Aprano wrote:
Also note: len(dict.keys()) == len(dict.values()) == len(dict)
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
', 1, m)))
line 174 ##
I cannot understand why the Python 2.7.1 interpreter complains
about NameError: global name 'levenshtein_automata' is not defined. On
line 125 , I try to define levenshtein_automata(self,term,k) as a
method of the class DFA. I am n
1
while b < 10:
print a, b,
a, b = a, b + 1
... do you think is there any reasonable way to transform the '0'
number into string and then back to numeral - after the printing action?
Use formatting: print '%i%i' % (a,b)
--
Bob Gailer
919-636-4239
Chapel Hill NC
:
print "%02d" % b
Personally I'd go for string formatting because of its much more
powerful and flexible options.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
Now that I understand what you want -
for b in range(120):
print '%0*i' % (max(2,int(math.log10(b))), b)
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription opt
On 12/28/2010 8:09 PM, bob gailer wrote:
Now that I understand what you want -
for b in range(120):
print '%0*i' % (max(2,int(math.log10(b))), b)
Sorry forgot to add
import math
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tuto
**
testdfa = DFA(1)
length = len(list(testdfa.find_all_matches('food', 1, m)))
line 174 ***
___________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
--
Bob
#x27;
>>> c = a + b
>>> print c
ab
Now you can recall seeing it.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
t the concatenation of s and t
a = 'a'
b = 'b'
c = a + b
print c
ab
Now you can recall seeing it.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription option
IN this case it is a waste of time. It could even do harm in cases
where you ingherit from a superclass that does have an init()
since the pass will mean it never gets called! Whereas if you
omit the init() the suiperclass init(if it exists) will get called.
HTH,
to be used by more than one main program.
HTH.
Please return with more questions.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
00):
s = eval("'" + 'wrtnjasdflkasjj'*n + "'")
t = eval("'" + 'wrtnjasdflkasjj'*n + "'")
if id(s) != id(t):
print n; break
whereas if I insert a ";" in the literal the program prints 1!
hy in the program I
posted I used the equivalent of eval("'" + letters*n + "'") which gives
different results than eval("letters*n")!
[snip]
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
, and also give us enough additional
details so we fully understand what you want.
Sample input - sample output would help a lot.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription
mped. Could it be the glasses you are wearing.
Or could you tell us just a bit more about your situation - such as
WHERE does this happen? An editor, IDLE, what?
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To uns
e code you wrote, so we have some idea of what you mean by "bind"
and "call".
I could guess but you should learn to provide sufficient information so
we don't have to.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tut
[0.0, 1.0).
The Python tool for converting float to integer is the int function.
However int(random.random() ) will always return 0.
In what range do you want the integers to fall?
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist
lt;= b.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
Thank you for seeking help.
Next time please start a new thread rather than "hijacking" an existing one.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription opt
sum = sum + 2**i
i = i - 1
dec_list.append(str(sum))
dec_ip = '.'.join(dec_list)
print dec_ip
if __name__ == '__main__':
bin_ip = sys.argv[1:]
convert(bin_ip)
If I knew the input to be perfect it would be a simple matter
'.'.join((str(int(input_ip[x:x+8],
t the literal integer number to its associated string
representation."""
return self.enums[literal]
Note this does not handle invalid literal.
If you are happy with range 14) you could alternatively use a list:
enums = ['transistor, 'mos', ...]
--
Bob Ga
is does not handle the upper/lower case issue.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
e a single
non-tuple object. [4] Otherwise, /values/ must be a tuple with exactly
the number of items specified by the format string, or a single mapping
object (for example, a dictionary)."
An easier way to create the list: self.board = [" "]*64
--
Bob Gail
mentioned earlier - TAPI is your friend.
And should I be thinking of it any differently than a USB port
which has 4 pins two data(+-), and two dc current(+-)?
As I warned above, YES.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist
is generally not what was
intended. A way around this is to use None as the default, and
explicitly test for it in the body of the function, e.g.:
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or cha
In future please start a new thread instead of hijacking an existing one.
We track things by thread, and I almost missed your question!
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change
or maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
e one-line version:
print [x*y for x,y in t]
or even better, in Python 3.x
[print(x*y) for x,y in t]
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.pytho
ould solve many problems.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
On 2/7/2011 2:45 PM, Eun Koo wrote:
Hi I have a problem in JES getting a solution to a function. Is there
a way you guys can help?
Maybe.
You might say more about the problem.
What is JES and how does it relate to Python?
--
Bob Gailer
919-636-4239
Chapel Hill NC
On 2/14/2011 4:59 PM, Daniel Otero wrote:
Did you want something?
If so state clearly and delete all non-relevant messages.
Did you notice:
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Tutor digest..."
--
Bob Gailer
919-636-4239
Chap
ToO(c1)
board.print1()
print("Game Over")
if __name__ == "__main__":
main()
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
1] != " ": print "Cell is occupied."
else:
board[int(cell)-1] = player
if any(1 for a,b,c in ((0,3,1), (3,6,1), (6,9,1), (0,7,3), (1,8,3),
(2,9,3), (0,9,4), (2,7,2)) if board[a:b:c] == [player]*3):
print player, "wins"
break
player
.org <mailto:Tutor@python.org>
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailma
On 2/20/2011 9:49 AM, Ben Ganzfried wrote:
Thanks, Bob.
I'd love some specific feedback. Exactly what did I offer that you found
useful?
Also please always reply-all so a copy goes to the list.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
How do you determine the type of an object?
1 - Use the type() function.
2 - notice '' around a and not around d
3 - Read the documentation:
bin(/x/) Convert an integer number to a binary string. The
documentation is weak here, but at least it tells you that the result is
a string.
Request:
When posting a question use a meaningful subject line, as some of us
track email by subject.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http
ke 20 powers, it will be long no ? is there
any solution shorter (and better ?)
1 - define a Power class and create instances
class Power:
def __init__(self, name, desc):
self.name = name
self.desc = desc
powerAll = [
Power('Flammes infernales' , 'Embrase lenemi et le
ot;
target.health -=self.strenght // care about it is - =
print (self.name <http://self.name>, "hit",target.name
<http://target.name>, "for", self.strenght, "damage")
Sorry, object is very new for me...
2011/2/24 bob gailer mailto:bgai...
ot;does not work" always show us what results you got as
well as what you wanted.
Also get in the habit of using Capitalized names for classes and
unCapitalized names for variables and functions.
powerAll is a list of class instaces. You must (in some way) identify
the attributes of those
character representation. This is not always ASCII. On IBM Mainframes it
is EBCDIC. The ord values are different, and the order is different.
See http://www.dynamoo.com/technical/ascii-ebcdic.htm
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist
to tell how
PyQuery relates to that table.
What have you tried? What results did you get? Why PyQuery as opposed to
another html tool such as Beautiful Soup?
The more you can tell us the easier it is for us to help.
--
Bob Gailer
919-636-4239
Chapel Hill NC
_
a.
if (i == 'test1') or (i=='test2'): is one way to do what you want.
Another is if i in ('test1', 'test2'):
Instead of a tuple of values you could also provide a list, a set or a
dictionary.
--
Bob Gailer
919-636-4239
Chapel Hill NC
_
h_command()
File "./main.py", line 44, in dispatch_command
method = self.GetMethod(args[0],args[1])
File "./main.py", line 25, in GetMethod
a=cls()
AttributeError: dispatcher instance has no __call__ method
The erro
Thanks for your response and for the rules, but for some reason I'm
not understanding. In the above quote, what is meant by "thing"?
Thing in this context means 'anything". could be a string, number, list,
any Python object.
True and 1 = 1
True and 'a'= &
between 1 - 100: "))
*if* guess > number :
*print* ("Too high")
*elif* guess < number :
*print* ("Too low")
*else*:
*print* ("Just right" )
That program is not the one you ran!
Something is missing!
Please also inform us:
Python Version
Operating Syste
t
items) which should return a negative, zero or positive number depending
on whether the first argument is considered smaller than, equal to, or
larger than the second argument: cmp=lambda x,y: cmp(x.lower(), y.lower())."
--
Bob Gailer
919-636
indirection in code reading).
def char(rec, tot): return tot + len(rec)
etc
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
ves under a key akin to a
dictionary.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
do this by adding the brackets around text output in line
26. This seemed to allow me to type main against margin rather than it
wanting to indent but didn't fix the problem. Your suggestions would
be appreciated.*
**
*Thank*
*Lea*
_
I have recently become a tutor to several Python students.
I enjoy tutoring and they benefit from it.
I work with some students using remote access, so we can be
geographically far apart.
Who do you know who might benefit from receiving one-on-one tutoring?
--
Bob Gailer
919-636-4239
IMHO % formatting is the easiest to use and understand.
I am sorry that it has been slated for removal.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http
der or destroy the material!
"STRICTLY PROHIBITED" oh I am so scared!
So there!
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
eturn
#If it gets this far, it's because the timer already ran, the player
is 'safe', and another check is being performed
self.auto_check()
Also note
if self.auto_check_timer == False:
can be simplified to
if
bscription options:
http://mail.python.org/mailman/listinfo/tutor
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
c approaches to this? I found the "timeit" module, but
that doesn't seem to be quite what I'm looking for.
I like to use the time module
import time
start = time.time()
rest of program
print time.time() - start
I believe that gives best precisioni on *nix
On Windows use time.c
video ... cannot be viewed from your currrent country ..."
Sigh.
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor
o me, as long as the file fits available
memory. There will be 2 copies of the file after the split.
Another way:
textFile = open('myfile','r')
for line in textFile:
if line.startswith('notes'):
notes = textFile.read()
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
On 4/15/2011 3:35 PM, Alan Gauld wrote:
"bob gailer" wrote
The show should be here - Pause at 1 minute 20 for the
Python screnshot:
http://fwd.channel5.com/gadget-show/videos/challenge/surprise-special-part-4
I am told "the video ... cannot be viewed from your currrent co
What magic?
Did you see an image of a monitor with 2 to the 38 on it?
Did you see "Hint: try to change the URL address."?
Did you try that?
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubs
the 3 files
finalmotifs = motif_file.readlines()
for line in seqalign:
for item in finalmotifs:
if item in line:
align_file.write('~' * len(line) + '\n')
# close the 3 files
--
Bob Gailer
919-636-4239
Chapel Hill NC
available as string methods.
string.capwords(s[, sep])
string.maketrans(from, to)
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo
does "list that has been opened from a text file" mean?
Is the source of the list important (e.g. does it matter whether it
comes from a file)?
Please provide an example. What does the list look like? How do you
determine which element you want?
Bob Gailer
919-636-4239
Chap
d_city"
function.
This stores a reference to the function. The following line is the call
to the function.
city_found = cities['_find'](cities,state)
[snip]
--
Bob Gailer
919-636-4239
Chapel Hill NC
___
Tutor maillist - Tutor@pytho
901 - 1000 of 1317 matches
Mail list logo