On Tuesday, January 12, 2016 at 11:27:23 PM UTC-6, Steven D'Aprano wrote:
> On Wednesday 13 January 2016 14:36, Rustom Mody wrote:
>
> > 1. Python the LANGUAGE, is rather even-handed in paradigm choice:
> > Choose OO, imperative, functional or whatever style pleases/suits
> > you 2. Python
On 1/11/2016 3:45 PM, Travis Griggs wrote:
On Jan 10, 2016, at 9:48 AM, Bernardo Sulzbach
wrote:
Essentially, classes (as modules) are used mainly for organizational purposes.
Although you can solve any problem you would solve using classes
without classes,
Guess you (Rodrigo) wanted to send this to the list?
On Wed, Jan 13, 2016 at 8:22 PM, Rodrigo Bistolfi wrote:
> Start by using just functions. As you move forward, you will find that
> often you are passing the same data structure as first argument to some
> functions. At that point, you
On Sunday, January 10, 2016 at 1:00:13 PM UTC+5:30, Arshpreet Singh wrote:
> Hello Friends, I am quite new to OOP(object oriented Programming), I did some
> projects with python which includes Data-Analysis, Flask Web Development and
> some simple scripts.
>
> I have only one question which is
On Wednesday, January 13, 2016 at 10:57:23 AM UTC+5:30, Steven D'Aprano wrote:
> On Wednesday 13 January 2016 14:36, Rustom Mody wrote:
>
> > 1. Python the LANGUAGE, is rather even-handed in paradigm choice: Choose
> > OO, imperative, functional or whatever style pleases/suits you
> > 2. Python
On Wednesday 13 January 2016 14:36, Rustom Mody wrote:
> 1. Python the LANGUAGE, is rather even-handed in paradigm choice: Choose
> OO, imperative, functional or whatever style pleases/suits you
> 2. Python LIBRARIES however need to make committing choices. Users of
> those then need to align
Chris Angelico wrote:
So start simplistic, and then look
into it like this: "Hey, see how you're doing this five times? There
HAS to be a better way!" (With acknowledgement to Raymond Hettinger.)
That gave me visions of a little animated cartoon of
Raymond popping up in the corner of the
On Tue, Jan 12, 2016 at 7:01 PM, Gregory Ewing
wrote:
> Chris Angelico wrote:
>>
>> So start simplistic, and then look
>> into it like this: "Hey, see how you're doing this five times? There
>> HAS to be a better way!" (With acknowledgement to Raymond Hettinger.)
>
>
On Mon, Jan 11, 2016 at 5:53 PM, Bernardo Sulzbach
wrote:
> I have never gone "seriously OO" with Python though. I never wrote
> from scratch an application with more than 10 classes as far as I can
> remember. However, I would suppose that the interpreter can handle
>
On Wed, 13 Jan 2016 11:18 am, Ian Kelly wrote:
> On Mon, Jan 11, 2016 at 5:53 PM, Bernardo Sulzbach
> wrote:
>> I have never gone "seriously OO" with Python though. I never wrote
>> from scratch an application with more than 10 classes as far as I can
>> remember.
On Mon, Jan 11, 2016 at 9:45 PM, Travis Griggs wrote:
>
>> On Jan 10, 2016, at 9:48 AM, Bernardo Sulzbach
>> wrote:
>>
>> Essentially, classes (as modules) are used mainly for organizational
>> purposes.
>>
>> Although you can solve any
> On Jan 10, 2016, at 9:48 AM, Bernardo Sulzbach
> wrote:
>
> Essentially, classes (as modules) are used mainly for organizational purposes.
>
> Although you can solve any problem you would solve using classes
> without classes, solutions to some big problems may be
On Tue, Jan 12, 2016 at 11:53 AM, Bernardo Sulzbach
wrote:
> On Mon, Jan 11, 2016 at 9:45 PM, Travis Griggs wrote:
>>
>>> On Jan 10, 2016, at 9:48 AM, Bernardo Sulzbach
>>> wrote:
>>>
>>> Essentially, classes (as
On 01/11/2016 04:45 PM, Travis Griggs wrote:
> As a long term OO purist practitioner, I would add to this.
> Obviously, you can organize your code any way you want, with or
> without classes. You could put all your functions with an odd number
> of letters in one class, and all of the even
On Mon, Jan 11, 2016 at 1:57 PM, Cameron Simpson wrote:
> I always structure this aspect as:
>
> ... at or near top of script ...
>
> def main(argv):
>... do main logic here ...
>
> ... at bottom ...
> if __name__ == '__main__':
>sys.exit(main(sys.argv))
>
> This has
On 10Jan2016 08:02, Michael Torrie wrote:
I can't speak to Flask or any other web development. But for simple
scripts, I'll start out with no classes. Just functions as needed, and
some main logic. I always use the idiom:
if __name__ == '__main__':
# do main logic here
On Sunday, 10 January 2016 23:20:02 UTC+5:30, Bernardo Sulzbach wrote:
> Essentially, classes (as modules) are used mainly for organizational purposes.
>
> Although you can solve any problem you would solve using classes
> without classes, solutions to some big problems may be cheaper and
> more
On Sunday, 10 January 2016 21:09:52 UTC+5:30, Steven D'Aprano wrote:
> There are *no* problems that are impossible to solve without classes, but
> sometimes classes will make problems easier to solve. And sometimes classes
> make problems harder to solve. It depends on the problem.
Is there any
On Sunday, 10 January 2016 20:33:20 UTC+5:30, Michael Torrie wrote:
> This way I can import functions defined in this script into another
> script later if I want.
>
> If I find I need to share state between functions, and if I find that I
> might need to have multiple situations of shared
On 10Jan2016 22:45, Arshpreet Singh wrote:
On Sunday, 10 January 2016 20:33:20 UTC+5:30, Michael Torrie wrote:
This way I can import functions defined in this script into another
script later if I want.
If I find I need to share state between functions, and if I find that
Cameron Simpson wrote:
> I always structure this aspect as:
>
> ... at or near top of script ...
>
> def main(argv):
>... do main logic here ...
>
> ... at bottom ...
> if __name__ == '__main__':
>sys.exit(main(sys.argv))
I, as a Python beginner, came to the same
On 01/10/2016 12:29 AM, Arshpreet Singh wrote:
> Hello Friends, I am quite new to OOP(object oriented Programming), I
> did some projects with python which includes Data-Analysis, Flask Web
> Development and some simple scripts.
>
> I have only one question which is bothering me most of the time,
Essentially, classes (as modules) are used mainly for organizational purposes.
Although you can solve any problem you would solve using classes
without classes, solutions to some big problems may be cheaper and
more feasible using classes.
If Python is your everyday scripting tool, you will
On Sun, 10 Jan 2016 06:29 pm, Arshpreet Singh wrote:
> Hello Friends, I am quite new to OOP(object oriented Programming), I did
> some projects with python which includes Data-Analysis, Flask Web
> Development and some simple scripts.
>
> I have only one question which is bothering me most of
Hello Friends, I am quite new to OOP(object oriented Programming), I did some
projects with python which includes Data-Analysis, Flask Web Development and
some simple scripts.
I have only one question which is bothering me most of the time, When I will
get the need to use Classes in Python?
25 matches
Mail list logo