Re: Bringing Order to programming

2019-01-31 Thread Ben Bacarisse
r...@zedat.fu-berlin.de (Stefan Ram) writes: > source = \ > 'Python is an easy to learn, powerful programming language. It has' + \ > ' efficient high-level data structures and a simple but effective' + \ > ' approach to object-oriented programming. Python's elegant syntax' + \ You have an unexsc

Re: Bringing Order to programming

2019-01-31 Thread Chris Angelico
On Fri, Feb 1, 2019 at 2:00 PM MRAB wrote: > > On 2019-02-01 00:28, Avi Gross wrote: > > The second variant is to use the newer bytearray data structure very > > carefully as it is to a first approximation a mutable string. Adding to the > > end of a new one should be quick. WARNING: I said be car

Re: Bringing Order to programming

2019-01-31 Thread MRAB
On 2019-02-01 00:28, Avi Gross wrote: The discussion moved on to debating if an algorithm is O(N) or O(N**2). For small amounts of text, on fast machines, it really is not worth worrying about the cost of appending to the end of a growing string resulting in multiple copies and lots of garbage c

Bringing Order to programming

2019-01-31 Thread Avi Gross
The discussion moved on to debating if an algorithm is O(N) or O(N**2). For small amounts of text, on fast machines, it really is not worth worrying about the cost of appending to the end of a growing string resulting in multiple copies and lots of garbage collection. Many computer textbooks love