Unbound Method Error
Enrico
4564 at 755189.45
Tue Jun 9 03:28:27 EDT 2009
"lczancanella" <lczancanella at gmail.com> ha scritto nel messaggio
news:32bf5ccb-5bfd-49a5-b423-9d41180a0ddb at l28g2000vba.googlegroups.com...
> Hi, i am brand new in Python, so sorry if this question is too basic,
> but i have tried a lot and dont have success... I have the following
> code...
>
> class Funcoes:
> def CifradorDeCesar(mensagem, chave, funcao):
A quick look to your code suggests to me to rewrite the above lines as:
class Funcoes:
@classmethod
def CifradorDeCesar(self, mensagem, chave, funcao):
@classmethod is needed since you call:
> atribdescripto = Funcoes.CifradorDeCesar (atribcripto,
3, 2)
Best regards,
Enrico
More information about the Python-list
mailing list