Thus spake ted b:
I am trying to figure out how to make a class instance respond the same way
> as another class instance if the other is affected by some event. I have
> been playing around with inheritance, and have tried other stuff, but i am
> somewhat of a newbie and I have been having diffic
Alan Gauld wrote:
"Marc Tompkins" <[EMAIL PROTECTED]> wrote
> realized I can implement this myself, using 'read(bigsize)' -
> currently I'm using 'read(recordsize)'; I just need to add an extra
> loop around my record reads. Please disregard...
On Nov 17, 2007 8:14 PM, Kent Johnson <[EMAIL PROTECTED]> wrote:
> Marc Tompkins wrote:
> > My question is this: does anybody know of an equivalent to
> > "readlines(sizehint)" for non-delimited, binary files? I've Googled
> > and Googled until I'
bled)
>
I think my head's going to explode - my negative capacity is overloaded!
On Nov 17, 2007 9:03 PM, Marc Tompkins <[EMAIL PROTECTED]> wrote:
> On Nov 17, 2007 8:14 PM, Kent Johnson <[EMAIL PROTECTED]> wrote:
>
> > Marc Tompkins wrote:
> > >
c. I'm trying to enhance performance, not kill it.
Thanks in advance for your insight -
Marc
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
On Nov 18, 2007 5:15 AM, Kent Johnson <[EMAIL PROTECTED]> wrote:
> Marc Tompkins wrote:
> > On Nov 17, 2007 8:20 PM, Kent Johnson <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> > use plain slicing to return the individual records instea
I have a specific question - how can I generalize a
FileBrowseButtonWithHistory - and I realized, as I was trying to word my
question, that my real question is a bit more generic.
First, the specific question: The FileBrowseButtonWithHistory requires a
callback override and some custom code to st
allback('fp2', x)
> )
> [snip]
> def fpCallback(self, controlID, evt):
> print evt.__dict__
> print help(evt)
> value = evt.GetString()
> [snip]
>
>
>
> - Jeff Younker - [EMAIL PROTECTED] -
>
>
> On
Sorry, meant to respond to the list, not just the OP...
-- Forwarded message --
From: Marc Tompkins <[EMAIL PROTECTED]>
Date: Dec 28, 2007 12:13 AM
Subject: Re: [Tutor] Dynamically named objects
To: Michael Bernhard Arp Sørensen <[EMAIL PROTECTED]>
I don't think
Here's the same thing with a list instead of a dictionary:
#===
class thingy():
example = "Just testing - "
def __init__(self, num):
self.example = self.example + str(num)
thang = []
for x in range(1,4):
thang.append(thingy(x))
for item,
On Dec 28, 2007 2:11 AM, Simone <[EMAIL PROTECTED]> wrote:
> bob gailer ha scritto:
>
> >> could you have a short review of my CLI package.
> > .bz2??? What does that extension mean? (For us Windows folk). Or could
> > you attach a simple zip file?
>
> .bz2 is an archive compressed with the bzip2
I'm using wxPython, after very brief forays into Tk and Qt, and I like it a
lot. wx generally wraps the native widgets of whatever OS/desktop it runs
on, and its idiom felt more comfortable to me than the others. Also, unlike
Qt, it's free... I hate to be a cheapskate, but I'm a very small busines
On Jan 3, 2008 4:06 AM, Tiago Saboga <[EMAIL PROTECTED]> wrote:
> But since 2005, according to wikipedia, the Qt Windows is also
> licensed under the GPL. Am I missing something?
>
>From the Trolltech website:
> *Qt Open Source Edition* is provided under the GNU General Public License
> version 2
On Jan 3, 2008 1:24 PM, Tony Cappellini <[EMAIL PROTECTED]> wrote:
> The point I was trying to make that didn't come across is:
> Until one has enough experience to hand code the GUIs, the designers are
> helpful and a good place to begin.
>
> The problem with widgets not appearing where they shou
On Jan 3, 2008 10:31 AM, Tony Cappellini <[EMAIL PROTECTED]> wrote:
> Putting widgets into sizers is easy with the designers. Not knowing how
> to fix your code when the widgets don't appear as you want them is a
> problem. I've never seen any docs written to help overcome this for any
> framewor
Let me clarify this:
> But if, to achieve the proper level of proficiency with the designer, I
> have to invest many hours of study and practice... well, it's going to be a
> hard sell. I'd rather be coding.
>
An hour spent learning something new in Python makes me a better programmer,
and proba
On Jan 7, 2008 12:07 PM, James Newton <[EMAIL PROTECTED]> wrote:
> Hi Python Practicioners!
> ...
> I am not so much concerned in getting this to work (I can already do
> that); I am more concerned with understanding how to treat this in the
> most Pythonesque way.
>
I'd like to get the party lin
On Jan 17, 2008 6:15 AM, Andy Cheesman <[EMAIL PROTECTED]> wrote:
> My only arising question is why should i
> "derive from object, so that you get a new-style class."
>
This list discussed this topic a couple of weeks ago. Recklessly
simplifying, it boils down to this: By using new-style classe
On Jan 24, 2008 5:28 PM, Timothy Sikes <[EMAIL PROTECTED]> wrote:
> I'm getting the "Digest" version of the mailing list, if there's any
> better way to respond to a specific message, I would like to know. thanks :>
>
I also originally signed up for the digest - it drove me up the wall, so I
subs
On Feb 5, 2008 5:46 AM, bhaaluu <[EMAIL PROTECTED]> wrote:
> What I'm interested in is the thought processes and/or
> guidelines that Tutors employ when they sit down to design a POOP.
Whenever I have a few free minutes and a desire to contemplate the
infinite (Hah!), I surf over to the C2 wiki.
> Sorry, my bad - this was my me, but I forgot to hit "Reply All".
My me? I think I meant to type "my message".
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Sorry, my bad - this was my me, but I forgot to hit "Reply All".
Here's a situation I often encounter, and I was wondering what the
"best practice" is. I've generally initialized my classes' attributes
this same way:
> class TestClass1(object):
> """ please give me a better name"""
> def
Sorry, I ALWAYS forget to hit 'Reply All'...
On Feb 16, 2008 3:18 PM, John Luke <[EMAIL PROTECTED]> wrote:
> I understand *what's* going on, but I don't understand *why* it's
> happening. To be more specific, I don't understand why the actual password,
> "unicorn", is what it is, even though I se
John, Luke, Marc... can we get a Matthew to join this thread?
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
>
> The indentation came through fine for me. The Basic code is indented
> with spaces, the Python code with tabs. Perhaps your mail reader doesn't
> correctly interpret the tabs.
>
This presents a perfect opportunity to remind our new Pythonistas that tabs
can be evil (for precisely this reason),
Mother Mary comes to me
Speaking words of wisdom:
Let it be, let it be...
On Feb 18, 2008 6:30 AM, Reed O'Brien <[EMAIL PROTECTED]> wrote:
> On Feb 16, 2008, at 9:58 PM, bob gailer wrote:
>
> > Marc Tompkins wrote:
> >> John, Luke, Marc... can we get a Matt
Sorry to jump in the middle here, but I have a somewhat related question...
I have a few websites set up for my clients, mostly using Mambo/Joomla
(PHP-based). My clients tend to be small brick-and-mortar businesses
(doctors, lawyers, etc.) who merely wish to use their website as an
extension of
hi.
i'm new to Python ...
i would like to extract the number of JPG files
from the current directory and use that number
as a parameter in my python script.
i tried:
a = os.system('ls *JPG | wc -l')
when i do:
print a
i get '0'.
7;, 'DSC2', 'DSC3']
i.e. the names w/o the file extension.
what's the easiest way of doing this?
marc
--
hi.
i want to pass an argument (a number) to a python
script when running it:
> python script.py
i want to be able to use within script.py
as a parameter.
how do i set this up?
marc
---
The apocalyp
text file.
note that all of the html files have the same
format, i.e. the text is always surrounded by the same
html tags.
also, i am sorting through thousands of
html files, so whatever i do needs to be
fast.
Michelle:
Are you familiar with writing functions?
Here I've created a function named getInputs.
I've also created a few test cases to verify that (a)
my understanding of the problem is correct, and (b) my
solution is correct.
It's important to think about how your program is
supposed to behave
I did a Google search for "python numeric sort" and
found
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/135435
It seems to do what you want.
Marc
--- Evan Klitzke <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I am trying to sort a list of directories that
> co
--- John Fouhy <[EMAIL PROTECTED]> wrote:
> On 12/07/06, Christopher Spears
> <[EMAIL PROTECTED]> wrote:
> > Now the exercise is:
> > As an exercise, rewrite this function so that it
> > doesn't contain any loops.
> >
> > I have been staring at this function and drawing a
> > blank. Something te
--- Terry Carroll <[EMAIL PROTECTED]> wrote:
> On Tue, 11 Jul 2006, Michael P. Reilly wrote:
>
> > Another aspect of your assignment will be to be
> able to use this
> > functionality from the "command-line". This
> means: without asking questions
> > from the user, but input is being passed
ges you've visited, all linked together, so
you can move backwards and forwards through the list.
Here is a great resource for learning about different
kinds of data structures:
http://www.nist.gov/dads
Regards,
Marc
__
Do You Yahoo!?
Tired of
--- "linda.s" <[EMAIL PROTECTED]> wrote:
> Python manual has a very brief introduction of
> "assert" statements. It
> is very difficult for me to understand it.
Every program has some fundamental assumptions that
must remain true in order for the program to continue
giving correct results.
The
--- [EMAIL PROTECTED] wrote:
> >>Python manual has a very brief introduction
> >>of "assert" statements. It is very difficult
>
> First you probably don't need to use asserts
> very often, they are useful if you are building
> production strength code but for most users
> of Python the exce
Look here:
www.ceebot.com
Not a book, but it might be what you are looking for.
--- Abel Daniel <[EMAIL PROTECTED]> wrote:
>
> Hi!
>
> I'm looking for a book to give to my younger brother
> as a birthday
> present. He is 13 years old, had some experience
> with logo (but not
> much, so he kno
--- Kefka Palazzo <[EMAIL PROTECTED]> wrote:
> I am trying to learn a programming language good for
> programming entire
> games (core functions too) similar to both the Final
> Fantasy and Metroid
> series. From the book I'm learning from (Python
> Programming for the Absolute
> Beginner, by Mich
--- Dick Moores <[EMAIL PROTECTED]> wrote:
>
> Andrei's
> Write your own iterator:
> >>> def hugerange(minval, maxval):
> ... val = minval
> ... while val < maxval:
> ... yield val
> ... val += 1
>
> All 3 are essentially the same, aren't they. Which
> makes me feel even
Sure sounds like XML to me... I'm just snatching a moment from Saturday
chores to type this, but there are a bunch of modules available for XML
manipulation - elementtree is built-in; I personally prefer Amara - and I'll
bet that a few minutes spent with the docs for either module will tell you
wh
2008/3/9 Emad Nawfal <[EMAIL PROTECTED]>:
> Thank you so much Kent. It works. I have now realized the bad things about
> self-learning.
>
There are bad things? Nobody told me...
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@python.org
http:
On Sun, Mar 9, 2008 at 4:02 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
>
> "Marc Tompkins" <[EMAIL PROTECTED]> wrote
> >... I have now realized the bad things about
> >> self-learning.
> >
> > There are bad things? Nobody told me...
>
Forgot to Reply All...
-- Forwarded message --
From: Marc Tompkins <[EMAIL PROTECTED]>
Date: Sat, Mar 15, 2008 at 2:13 AM
Subject: Re: [Tutor] my first project: a multiplication trainer
To: Guba <[EMAIL PROTECTED]>
On Fri, Mar 14, 2008 at 9:43 PM, Guba <[EMAIL PR
On Sun, Mar 16, 2008 at 10:59 AM, jake cooper <[EMAIL PROTECTED]>
wrote:
> print 'You inflicted', damage_to_enemy, "points of damage to your
> enemy" #shows damage dealt
> temp_e_hp - damage_to_enemy #!!!attempts to deduct damage_to_enemy
> from temp_e_hp!!!
> print temp_e_hp**
>
*
On Wed, Mar 19, 2008 at 3:56 PM, Tim Michelsen <[EMAIL PROTECTED]>
wrote:
> m = 0
> cm = 0
> mm = 0
> ## first list item
> if first.endswith("m",-1):
> m = first.strip("m")
> elif first.endswith("cm",-2):
> cm = first.strip("cm")
> elif first.endswith("mm",-2):
> mm = first.strip("mm")
On Fri, Mar 21, 2008 at 12:42 PM, Spencer Parker <[EMAIL PROTECTED]>
wrote:
> This is all that I get when I run it...
>
> Traceback (most recent call last):
> File "./loadcsv.py", line 23, in ?
> co.execute("""
> File "/usr/lib64/python2.4/site-packages/MySQLdb/cursors.py", line 148,
> in
Sorry... no, it still shouldn't work...
maybe like so:
co.execute('''INSERT INTO stats
VALUES("%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s"
% row''')
> You have triple quotes around your SQL. That means that "implied" line
> breaks become real. It won't look as ni
On Sun, Mar 23, 2008 at 4:16 PM, elis aeris <[EMAIL PROTECTED]> wrote:
> in c++ i use array[n][n] to store things.
>
> how do i create an array like that?
>
Python doesn't have "arrays". It has tuples, lists, and dictionaries. A
quick Google will tell you the distinctions between them.
It look
On Sun, Mar 23, 2008 at 4:24 PM, elis aeris <[EMAIL PROTECTED]> wrote:
> Now I want to talk about this: how should I have asked my Q to let
> everyone know what I was looking for?
>
> looking back to my first post, it seems to be a little weak. Can you
> suggest something that I could have said?
>
On Sun, Mar 23, 2008 at 4:41 PM, elis aeris <[EMAIL PROTECTED]> wrote:
> def returning ():
> a = 1
> b = 2
> return a, b
>
>
> ab = returning()
>
>
> does this work?
>
I cut and pasted into an interactive Python session:
>>> def returning ():
... a = 1
... b = 2
... retur
On Mon, Mar 24, 2008 at 6:28 AM, Bartruff, Pamela J. <
[EMAIL PROTECTED]> wrote:
> Def convert_time(time):
> """split hours from minutes"
> Time = raw_input("enter a time, in military: ")
>
At this point, Time is a string, not a number. (At this point, we also have
to _assume_ that the user ente
Sorry - forgot to reply to the list the first time...
On Sat, Apr 5, 2008 at 3:04 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
> On Windows you can use FC - File Compare.
> Its not as powerful as diff but it will highlight differences.
>
On Windows, I've tried a bunch of diff tools - it's probably t
On Mon, Apr 7, 2008 at 4:52 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
> "Dick Moores" <[EMAIL PROTECTED]> wrote
>
> > Could you give a blow-by-blow on the dis.dis()?
>
> I'll have a go but I've never actually studied Python P-Code,
> this is based on my 8080 and 68000 assembler experience!
> ...
>
On Thu, Apr 10, 2008 at 9:14 AM, linuxian iandsd <[EMAIL PROTECTED]>
wrote:
> I have been used to making queries to websites automatically & analizing
> the results. a few minutes ago ... i can no longer do that
> now a website is protected by a ramdom number that i have to enter before
> i can lo
nly struck me that someone out there may have done this before. (And
yes, I've definitely Googled, but my Google-fu may be weak today.) If
anyone has insight into RTF Zen, or has some tips on batch macros in oO, I'd
be obliged...
Marc
--
www.fsrtechnologies.com
___
On Tue, Apr 15, 2008 at 7:18 PM, <[EMAIL PROTECTED]> wrote:
> Recommendation: Find a very old version of Word (Word 95) to generate
> your RTF 'templates'. The older versions of Word generate much simpler
> RTF that is forward compatible.
>
Excellent advice! Unfortunately, my case is a bit diffe
On Tue, Apr 15, 2008 at 7:10 PM, John Fouhy <[EMAIL PROTECTED]> wrote:
> Is this any help to you: http://pyrtf.sourceforge.net/
>
Not so much, because it only produces RTF - it doesn't help me pick apart
the stuff I've already got.
(It did cross my mind to try to create in pyRTF the same structur
On Tue, Apr 15, 2008 at 8:50 PM, Luke Paireepinart <[EMAIL PROTECTED]>
wrote:
> Sorry, forgot to cc the list.
>
Actually, you cc'd the list with my previous post instead of your response
to it. Here's what you sent me:
> I don't know if this is the best way, but given that other guy's
> suggesti
Again with the forgetting to cc the list...
On Tue, Apr 15, 2008 at 11:33 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
> Alternatively learn enough VBScript to do it all in Word itself
That's exactly what I'm doing now. After mentioning in a previous email
that formatting is important, I took
Just as a followup - I ended up using a Python script to recurse through
the folders of files and, for each file found, extract the
doctor/date/medical record number from the filename, then run a Word macro
on the file to insert the header slug.
If anyone ever needs to do something similar, or ju
I don't know whether there are any other xkcd fans here, but I am, and I was
very happy to see Python mentioned again...
http://xkcd.com/413/
Sometimes it really does seem that easy.
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@python.org
h
I for one would like to thank Bob for asking the question! So far I hadn't
had the guts.
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
Just thought I'd share something I found quite humorous... a while back, I
heard about Microsoft's "Open Source Hero" program, and being a curious type
I signed up. Hey, I love me some Open Source, and I wanna be a hero, right?
My Hero Pack arrived a few days ago. It contains:
a 90-day trial o
On Tue, Apr 29, 2008 at 9:22 AM, Scott SA <[EMAIL PROTECTED]> wrote:
>- More than one space around an assignment (or other) operator to
> align it with another.
>
When I first started in Python, I was lining up all of my variable
assignments in blocks; I, too, find it more readable. But
On Thu, May 1, 2008 at 12:51 AM, Ross Glover <[EMAIL PROTECTED]> wrote:
> put, get=os.popen4("dict -d wn " + (word))
>
> Something that can be a little confusing at first (and I haven't seen
anybody mention it yet, so I thought I'd chime in) is that you can assign
multiple variables at the same ti
On Thu, May 1, 2008 at 4:02 PM, bob gailer <[EMAIL PROTECTED]> wrote:
> Marc Tompkins wrote:
> >
> > In contrast, this line runs a command that returns two values
> >
>
> No No. Python does not have "commands" and can't therefore "run"
On Mon, May 5, 2008 at 5:21 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
> Probably but I'm not totally clear what you are looking for.
> Can you explain what you mean by the diffrence between the size
> used versus the size of the image? Surely the size of the image
> is the space it uses? Or are yo
On Mon, May 5, 2008 at 11:55 PM, Alan Gauld <[EMAIL PROTECTED]>
wrote:
>
> As to finding disk usage on Windows I found this
> snippet on an MSDN forum:
>
> --
> If you want the size of the file on disk when compressed or sparse
> then you have to use Platform/Invoke to call GetComp
On Tue, May 6, 2008 at 9:46 AM, Robert Kirkpatrick <[EMAIL PROTECTED]> wrote:
> Hey Alan! Is there a dict program for the MacOS flavour of *nix? That's
> a
> slick little bit of code but it doesn't work on my Mac:
>
> robertk01$ dict
> -bash: dict: command not found
>
> but it works fine when I
On Tue, Jun 10, 2008 at 10:07 AM, dave selby <[EMAIL PROTECTED]>
wrote:
> Hi All,
>
> Up to now I when I need to write some data to a file I have been
> purposely using close()
>
> f = open(conf, 'w')
> f.writelines(lines)
> f.close()
>
> Is it as safe to use the following
>
> open(conf, 'w')
On Tue, Jun 24, 2008 at 6:40 AM, John Patrick Gerdeman <
[EMAIL PROTECTED]> wrote:
> (You could potentially start the sequence anywhere, e.g at a=5 and b=7, or
> over all prime numbers, it
> would still be a Fibonacci sequence, though not the one commonly known)
>
Actually, a series that follows
On Wed, Jun 25, 2008 at 2:21 PM, chase pettet <[EMAIL PROTECTED]> wrote:
> import os, time, sys
> current = time.time()
> os.chdir("c:\BACKUPS\DEV1")
>
> for f in os.listdir('.'):
> modtime = os.path.getmtime('.')
> if modtime < current - 30 * 86400:
> os.remove(f)
>
I'm not in a place w
On Mon, Jul 7, 2008 at 9:40 AM, Jeremiah Stack <[EMAIL PROTECTED]> wrote:
>
>
> Hello everybody:
>
> I am new to this mailing list, and it said that i could the simplest of
> questions. So i was wondering if anyone could be so kind as to e-mail me a
> project idea or something to go out an learn t
I did wonder whether there was a joke there... is the Pythong the hot new
trend in beachwear?
On a creepier note, if you make the mistake of going to python dot com
instead of dot org, a Pythong is the least of your worries... eeewww.
--
www.fsrtechnologies.com
_
On Tue, Jul 8, 2008 at 3:29 PM, Christopher Spears <[EMAIL PROTECTED]>
wrote:
> I have been reading everyone's comments on my line class. I have decided
> to implement some of the suggestions. Someone suggested that I create a
> Point.__cmp__ method. Here is what I have so far:
>
> def __cmp__(
On Sat, Jul 12, 2008 at 8:10 PM, Dick Moores <[EMAIL PROTECTED]> wrote:
> But why will a tuple with two elements will always evaluate to
> True?
>
> In [2]: (3,5) == True
> Out[2]: False
> In [3]: ("qwerty", "asdfg") == True
> Out[3]: False
> In [4]:
>
>
The value formally known as True is only on
On Sun, Jul 13, 2008 at 1:06 PM, Dick Moores <[EMAIL PROTECTED]> wrote:
> In other words, "(3,2)" isn't exactly the same as "True" - but it doesn't
> evaluate to False, either, so it's true.
>
>
> So what does (3,2) evaluate to? Or is that a meaningless question? However
> in the following exampl
Forgot to send to the list...
On Sun, Jul 13, 2008 at 1:06 PM, Dick Moores <[EMAIL PROTECTED]> wrote:
> Or is there an ambiguity in "evaluate" in Python that is well-understood
> and doesn't cause a problem?
>
I should simply have said: "evaluate" is not a word IN Python (although
"eval()" is,
On Tue, Jul 15, 2008 at 11:41 AM, Mayank Agarwal <[EMAIL PROTECTED]>
wrote:
> Hi,
> i have a look on error_log and the error is following:
> [Tue Jul 15 21:17:03 2008] [error] [client 10.73.41.64] (8)Exec format
> error: exec of '/etc/httpd/cgi-bin/final.php' failed
> [Tue Jul 15 21:17:03 2008] [e
On Mon, Jul 21, 2008 at 10:29 AM, Marc Tompkins <[EMAIL PROTECTED]>
wrote:
>
> How about
>
>> return (x!=0)
>>
> ?
>
> Short and cryptic!
>
Sorry - I had deleted all the old messages in the thread, and only responded
to the latest. My bad - I see now t
On Mon, Jul 21, 2008 at 10:20 AM, Daniel Sarmiento <[EMAIL PROTECTED]>
wrote:
> What about the following function?
>
> if x == 0:
>return False
> return True
>
>
> I am a beginner, but I think it is more clear (at least to me) what
> the function does. And it is only one line longer than
>
> v
On Thu, Jul 31, 2008 at 8:16 PM, Angela Yang <[EMAIL PROTECTED]> wrote:
> Hi,
>
> I have a list of values for one key. How do I specify this data structure?
>
> First tried,
>
> collection = []
> collection['abby'].append('apprentice1')
> collection['abby'].append('apprentice2')
>
> That did not
notice already these ?
thanks for you feedback
Marc
___
Tutor maillist - Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor
On Wed, Aug 13, 2008 at 1:10 AM, vishwajeet singh <[EMAIL PROTECTED]>wrote:
> I use pydev eclipse plugin for python and it saves me alot time.
> Packages and modules can be maintained pretty well and if error is in some
> dependent file I dont have to go to that folder to open it eclipse does it
>
On Wed, Aug 13, 2008 at 4:15 AM, Dick Moores <[EMAIL PROTECTED]> wrote:
> I've marked your list with *** for yes; ### for no; ??? for not sure or not
> sure what you mean.
>
At 03:06 AM 8/13/2008, Marc Tompkins wrote:
>
>- Todo list ??? But TODO's in code ar
On Wed, Aug 20, 2008 at 2:30 AM, Jim Morcombe <[EMAIL PROTECTED]>wrote:
> I have an object called "myObject" with an attribute called "colour".
>
> If I type:
> print myObject.colour
> then python prints:
>red
>
> Now, I have a variable "myAttribute" and set its value to "colour" by
> typin
On Thu, Sep 4, 2008 at 6:00 PM, Roy Khristopher Bayot <[EMAIL PROTECTED]>wrote:
> Correct me if I am wrong but each "import os" statement only exists in each
> method. Is there a way to only import the os module once and use it in each
> method?
>
Move it to the top of the file, outside of the
On Thu, Sep 11, 2008 at 3:58 AM, Wayne Watson
<[EMAIL PROTECTED]>wrote:
> Is it possible in Python to look at a string as a "struct". I don't think
> a struct exists in python. Actually, is there something analogous to a
> record. In the case of strings, suppose I have string that is composed of
On Sat, Sep 13, 2008 at 6:02 PM, Alan Gilfoy <[EMAIL PROTECTED]>wrote:
> I found a script at http://code.activestate.com/recipes/65212/ that allows
> you to convert base 10 numbers to another base.
I would like to convert non-base10 numbers to base 10. I wonder if I can do
> so by flipping the sc
On Sun, Sep 14, 2008 at 4:48 AM, Kent Johnson <[EMAIL PROTECTED]> wrote:
> The docs say, "If radix is zero, the proper radix is guessed based on
> the contents of string; the interpretation is the same as for integer
> literals."
>
> 'guessed' is not really a very good choice of words; 'determined
On Sun, Sep 14, 2008 at 2:29 PM, Kent Johnson <[EMAIL PROTECTED]> wrote:
> On Sun, Sep 14, 2008 at 3:34 PM, Marc Tompkins <[EMAIL PROTECTED]>
> wrote:
> > On Sun, Sep 14, 2008 at 4:48 AM, Kent Johnson <[EMAIL PROTECTED]> wrote:
> >> 'guessed' is no
>
> I'm looking at a GUI application that I hope to modify in the next few
>> weeks. When it's executed the expected GUI appears along with a DOS window.
>> Occasionally, I think, I've seen something put in the DOS window. How do I
>> stop it from appearing and how do I find why it's used?
>>
>
> I
On Mon, Sep 29, 2008 at 2:55 AM, Alan Gauld <[EMAIL PROTECTED]>wrote:
> The biggest limitation by far on Python web development is lack
> of Python support on the web servers. You need to find a provider that
> either gives you an account on a server with which you can install any
> frameworks you
On Tue, Oct 14, 2008 at 9:23 AM, URBAN LANDREMAN <[EMAIL PROTECTED]> wrote:
> Thanks for the suggestion.
>
> When I ran the slightly modified code:
> import win32com.client
> app = win32com.client.Dispatch('Word.Application')
> docOrig =
> app.Documents.Open('n:\\MetroPlanners\\2006\\MCHResearchPr
On Tue, Oct 14, 2008 at 11:54 PM, Marc Tompkins <[EMAIL PROTECTED]>wrote:
> so if you turn your list into a tuple (I can never remember, is that a cast
> or a coercion?)
>
To answer my own question: neither, but it's closer (in spirit) to a cast.
--
www
Dictionary keys must be immutable - in other words, they must be objects
that aren't allowed to change. Lists can change, so the answer is no.
However, tuples are immutable, so if you turn your list into a tuple (I can
never remember, is that a cast or a coercion?), you can use it as a
dictionary
On Wed, Oct 15, 2008 at 12:22 AM, wesley chun <[EMAIL PROTECTED]> wrote:
> >> so if you turn your list into a tuple (I can never remember, is that a
> >> cast or a coercion?)
> >
> >> lX = tuple(lX)
> >
> > To answer my own question: neither, but it's closer (in spirit) to a
> cast.
>
> you're kee
>
> ...
>> http://www.python.org/doc/current/tut/tut.html
>>
>
Reminds me of Christopher Robin helping Winnie-the-Pooh try to fool the
bees: "Tut tut, looks like rain! Tut tut, looks like rain!"
--
www.fsrtechnologies.com
___
Tutor maillist - Tutor@
101 - 200 of 459 matches
Mail list logo