[Tutor] python2vb.net

2006-10-25 Thread hok kakada
Dear All, A friend of mine is well programming in vb.net and C#. He got a python sourcecode of KhmerConverter tool. He would like to port to either vn.net or C#. Are there any tools to do this? Thanks, da ___ Tutor maillist - Tutor@python.org http:/

[Tutor] New to programming and Python

2006-10-25 Thread Jorge Azedo
Hi guys ( and gals ) I'm totally new to the whole programming scene (I decided to enter it for many reasons, one of which is the fact that I *want* to know how to program my computer) and I decided to start out with Python. I'm reading lots of tutorials on it, trying to understand how to work w

Re: [Tutor] Decimal truncation, rounding etc.

2006-10-25 Thread Joe Cox
Yes, I made a typo in the quantize. You are correct I am not able to read and parse the text file properly?  I just face that IDE screen and it's all white. I am lost.  -Original Message-From: Jason Massey [mailto:[EMAIL PROTECTED]Sent: Wednesday, October 25, 2006 4:25 PMTo:

Re: [Tutor] Decimal truncation, rounding etc.

2006-10-25 Thread Jason Massey
More specifically, Joe, where and what types of errors are you getting?When I type in your example exactly as above I get the following:>>>from decimal import *>>> Decimal('7.').quantize(Decimal('1.000'),rounding=decimal.ROUND_DOWN)Traceback (most recent call last):  File "", line 1, in ?NameE

Re: [Tutor] Decimal truncation, rounding etc.

2006-10-25 Thread Luke Paireepinart
Joe Cox wrote: > My next project is to read a doc file and do some number editing. > I can alter numbers in the Interactive Shell OK: > > import math > print round(7.12345,4) > 7.1234 > > from decimal import* > Decimal('7.0').quantize(Decimal('1.000'),rounding = > decimal.ROUND_DOWN) > Dec

[Tutor] Decimal truncation, rounding etc.

2006-10-25 Thread Joe Cox
My next project is to read a doc file and do some number editing. I can alter numbers in the Interactive Shell OK:   import mathprint round(7.12345,4)7.1234   from decimal import*Decimal('7.0').quantize(Decimal('1.000'),rounding = decimal.ROUND_DOWN)Decimal("7.")   But when I go in

Re: [Tutor] Self, Scopes and my unbelievable muddleheadedness.

2006-10-25 Thread John Fouhy
On 26/10/06, doug shawhan <[EMAIL PROTECTED]> wrote: > class Create: > def freshDB(self, DBPATH, Fields): > # ... > def comparisonTable(self, DBPATH, Fields, columns, mode): > # ... > Now when I run freshDB from the other script: > > Fields = {"Common":"Inventory_Nu

Re: [Tutor] Self, Scopes and my unbelievable muddleheadedness.

2006-10-25 Thread Luke Paireepinart
> > I'm sure this is so obvious that a crack-addled tapeworm head down in > a bucket of stupid could understand it, unfortunately, I'm not quite > at that level today. Sorry. Uh, I don't understand why you're passing Fields to the functions but then putting the value in self.Fields... but we'll

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread wesley chun
on a related topic, if you're concerned about security, esp. of your instance attributes, new-style classes offer you significantly more control over them using descriptors (including properties [and to a lesser extent, slots]). there is plenty of docs available on those, so i'll defer describing t

[Tutor] Self, Scopes and my unbelievable muddleheadedness.

2006-10-25 Thread doug shawhan
I'm having a rather difficult time understanding the proper use of "self". I have two functions (yes, they are ugly, I was getting ready to split them in to smaller bits when this particular hole in my skull opened up) in a module. They use the same list of dictionaries to create some tables in a

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Asrarahmed Kadri
Chris, you are right. He (Alan) hits the bull's eye, always !!   Cheers...   Asrarahmed  On 10/25/06, Chris Hengge <[EMAIL PROTECTED]> wrote: I dont know about the rest of you, but this thread posting from Alan cleared up some fuzzyness I've had about classes. /me is happier using this. instead of

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Asrarahmed Kadri
  Thanks a lot for explanation.   Regards, Asrarahmed  On 10/25/06, Alan Gauld <[EMAIL PROTECTED]> wrote: "Asrarahmed Kadri" <[EMAIL PROTECTED]> wrote > Why is it necessary to explicity use self argument in the class> functionsBecause Guido made it that way. :-)But he did it for good reasons which

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Chris Hengge
I dont know about the rest of you, but this thread posting from Alan cleared up some fuzzyness I've had about classes. /me is happier using this. instead of self. =DGreat post! On 10/25/06, Alan Gauld <[EMAIL PROTECTED]> wrote: "Asrarahmed Kadri" <[EMAIL PROTECTED]> wrote> Why is it necessary to ex

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Alan Gauld
"Asrarahmed Kadri" <[EMAIL PROTECTED]> wrote > Why is it necessary to explicity use self argument in the class > functions Because Guido made it that way. :-) But he did it for good reasons which others have pointed out already. Although languages like C++ and Java use implicit object reference

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Andrei
Asrarahmed Kadri googlemail.com> writes: > the use of 'self' keyword really confuses me. I see how it can annoy you, but not how it can *confuse* you - if anything, "self" removes any confusion about whether you're looking at a local variable or an object property. By the way, the use of specia

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread euoar
Asrarahmed Kadri escribió: > > > Folks... > > Please dont take it in a wrong sense. But I have a point to make > regarding OOP and the way it is implemented in Python. > > Why is it necessary to explicity use self argument in the class > functions ?? I feel the language/interpreter shoul

Re: [Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Simon Brunning
On 10/25/06, Asrarahmed Kadri <[EMAIL PROTECTED]> wrote: > Why is it necessary to explicity use self argument in the class functions > ?? I feel the language/interpreter should figure out which object has called > the function? Isnt it ? (the use of 'self' keyword really confuses me. and > to make

[Tutor] OOP and Python.. a gentle remark

2006-10-25 Thread Asrarahmed Kadri
    Folks...   Please dont take it in a wrong sense. But I have a point to make regarding OOP and the way it is implemented in Python.    Why is it necessary to explicity use self argument in the class functions ?? I feel the language/interpreter should figure out which object has called the functi

[Tutor] http://www.google.com/coop/cse?cx=010104417661136834118%3Aat1-hsftvfo

2006-10-25 Thread anil maran
http://www.google.com/coop/cse?cx=010104417661136834118%3Aat1-hsftvfo Anil __ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com ___ Tutor maillist - T