Re: about types.new_class and module

2019-03-04 Thread Jimmy Girardet
Thank you for the clarification. I thought everything was bounded to anything. Shouldn't the name be changed from `types.A` to `unbound.A` to be less confusing ? Le 04/03/2019 à 20:31, MRAB a écrit : 'new_class' creates a new class with the given name and returns a reference to it. The c

about types.new_class and module

2019-03-04 Thread Jimmy Girardet
Hello, I'm looking for an explanation where live classes created by types.new_class() : py> import types py> types.new_class('A') types.A py> types.A AttributeError: module 'types' has no attribute 'A' py> _.__module__ 'types' The new class comes from `types` module without being inside.

Re: more pythonic way

2019-02-11 Thread Jimmy Girardet
The first one is used very often. Less verbose Le 11 févr. 2019 à 20:41, à 20:41, Felix Lazaro Carbonell a écrit: > > >Hello to everyone: > >Could you please tell me wich way of writing this method is more >pythonic: > > > >.. > >def find_monthly_expenses(month=None, year=None): > >