Changing the private variables content

Dave Angel davea at ieee.org
Wed Jul 22 11:39:51 EDT 2009


Ryniek90 wrote:
> <snip>
>
>
> It looks like private variable have specific naure, that prevent from 
> traditional editing them.
> Still searching for some tuts about private methods and variables.
>
>
There's no tutorial on private variables for good reason:

Private variables have no special characteristics.  The compiler and 
runtime library don't treat them specially (except for the highly 
controversial from xx import *).  It's strictly a programming 
convention.  You've got some other bugs in your code, which I can't help 
you with because your code comes across formatted so strangely that it 
cannot compile here.  Some things you might do to make it easier to get 
help:

1) make sure you're not mixing tabs and spaces in your source code
2) post using text messages, so they don't get reformatted.
3) copy/paste the code and error messages into your message, don't retype.
4) whenever you've made more than trivial changes to the code, repost it 
all, since it's very difficult to tell which suggestions you've 
followed, and which ones you haven't gotten yet, or maybe dismissed 
because they didn't work.

DaveA




More information about the Python-list mailing list