On 2013-05-06, Mark Lawrence wrote:
> On 06/05/2013 13:06, Neil Cerutti wrote:
>> On 2013-05-03, John Gordon wrote:
>>> In Neil Cerutti
>>> writes:
>>>
>>>> Not quite yet. Players who guess correctly on the fifth try don't
>>>>
> highway_dict['lanes'], highway_dict['state'],
> highway_dict['limit(mph)'] = lanes, state, limit_values
> queue_row.append(highway_dict)
Can you provide a short example of input and what you had hoped
to see in the lists and dicts at the end?
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
postrophe for pluralisation.
If there's no chance for confusion between a class named FooEntry
and another named FooEntries, then the first attempt seems best.
Pluralize a class name by following the usual rules, e.g.,
"strings" and "ints".
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-05-09, Jussi Piitulainen wrote:
> Neil Cerutti writes:
>> If there's no chance for confusion between a class named
>> FooEntry and another named FooEntries, then the first attempt
>> seems best. Pluralize a class name by following the usual
>> rules, e.g.
pected output from
it, chances are you aren't ready to start writing code.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
, who taught that heavier
objects fall faster, was walking past.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
reflection it
speciously inserts the word "irrelevant" in order to avoid
stating a tautology: A programming language is low level when its
programs require attention to low level details.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-05-13, F?bio Santos wrote:
>
> On 13 May 2013 19:48, "Neil Cerutti" wrote:
>>
>> On 2013-05-13, Skip Montanaro wrote:
>> >> 8. A programming language is low level when its programs
>> >> require attention to the irrelevant.
&g
read I hope I don't have to till a garden,
plant the wheat, harvest the wheat, and grind the wheat. But
gardening is relevant to bread baking weather or not I do it.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
n the level of problem
for which a programming language is most appropriate.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
Everybody." I didn't write it myself--I wrote it some asshole.'
--Steve Martin
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-05-22, Tim Chase wrote:
> On 2013-05-22 01:15, i...@databaseprograms.biz wrote:
>> A computer programmer, web developer and network administrator
>
> ...walk into a bar...
>
> So what's the punchline?
"Ow." Get it? "Ow."
--
Neil Cerut
the definition. Where are
you perceiving wiggle room?
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ograms like the remake of Dawn of the GREP, just
aren't as scary.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
__name__: cls for cls in (A, B)}
ArgType = classes[sys.agrv[1]]
arg = ArgType()
arg.in("test")
arg.out("test")
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
m Python 2 and 3
>> in a single file.
>>
>> Is that possible? How?
You need sys.version_info.
For more, see http://python3porting.com/noconv.html
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
r.
I propose borrowing the concept of significant digits from the
world of Physics.
The above has at least three significant digits. With that scheme
x would approximately equal 17.3 when 17.25 <= x < 17.35.
But I don't see immediately how to calculate 17.25 and 17.35 from
17.3, 00.1 an
iting the modified module back to a file so that I can still
> use py_compile.compile() to byte compile that code.
You would use StringIO instead of writing a temp file.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
27;=' not in month and '=' not in year:
>
> It'd be courteous to acknowledge those who made that
> suggestion, most notably alex23 who posted it in almost that
> exact form.
Also, I wish he would stop fudging his From info. I've got
something like 8 entries fo
On 2013-06-11, dhyams wrote:
>> You would use StringIO instead of writing a temp file.
>
> I don't think that would work...py_compile takes a filename as
> input, not a file object.
Dang. Sorry for the misinfo.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ch you didn't tell us here, including which database you are
>> using.
>
> Are you guys _still_ on Nikos hook?
>
> [No, I don't really think he's trolling, but it would be really
> impressive if he were.]
He's definitely trolling. I can't think of any other reason to
make it so hard to kill-file himself.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-06-12, Mark Lawrence wrote:
> On 12/06/2013 13:42, wrote:
>>
>> Something you want me to try?
>
> I'd suggest suicide but that would no doubt start another
> stream of questions along the lines of "How do I do it?".
hi. I loopet rope aroung and jumped, but br
On 2013-06-12, Zero Piraeus wrote:
> On 12 June 2013 10:55, Neil Cerutti wrote:
>>
>> He's definitely trolling. I can't think of any other reason to
>> make it so hard to kill-file himself.
>
> He's not a troll, he's a help vampire:
>
&g
r
is, much, much simpler. Unless there's some non-trivial need to
use Excel directly I strongly recommend exporting as csv and
using the csv module.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
worst of all, there's none of the closure or
vicarious catharsis that usually comes from a well-designed
educational transaction.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ts in GUI interface have
built-in stengths and weaknesses. I was going to write something
about them earlier, but I got bogged down when I thought of the
issue of accessibilty, which overtakes any such discussion.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
PIL for this
project, instead of PyGame. I have not personally used PyGame,
but my guess is it will be much harder to create a reasonable GUI
with PyGame than with tkinter. But I do not know how difficult
this project will be will be even using the libraries of least
resistance. The GUI you propose is very simple, except possibly
for the dragging and dropping, which I've not tried and might be
hairy. Moreover, I have not seriously used PIL and I don't even
know if it supports Python 3.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
acket, quote or
colon.
So if you press enter and the autoindent is unexpected, don't
just press space or backspace to fix it. It's usually a sign of
an earlier syntax error, so look for that first.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-06-20, Cameron Simpson wrote:
> On 20Jun2013 13:55, Neil Cerutti wrote:
>| On 2013-06-20, Joshua Landau wrote:
>| > On 20 June 2013 04:11, Cameron Simpson wrote:
>| >> Also, opening-and-not-closing a set of brackets is almost the
>| >> only way in Pyt
rrectly, you have to have mastered three separate Python
concepts.
1. How name-binding works.
2. How argument passing works, i.e., via name-binding.
3. When default arguments are evaluated.
4. The Python object model.
OK, you have to know four things. Curses! I'll come in again.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ar. If you're thinking of
>> this as a fabric replacement, I would go with cloth, textile, material,
>> gabardine, etc.
>
> Snakeskin? Oh, I see that's already taken. :-(
Most things are taken nowadays.
A short nonsense-word is best. Something like "Folaf". Yeah, it
doesn't spark the imagination, but it's easy to find, if not to
remember.
Well, not "Folaf." That seems to be an African style restaurant
in L.A.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
armful like a
> religious edict.
The one-exit-point rule is helpful for tracking entry and exit
invariants. But in my view it shouldn't be followed when it makes
code worse.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
= {
True: lambda: print("No name longer than 20 letters."),
False: lambda: True,
}[len(name) > 20]()
Much better.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
s are not only for spam. I filter out
anything I believe I won't want to see.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
return true for only
> these tables:
> MY_TABLE
> YOUR_TABLE
Use the "is not a word" character class on either end.
r"\WMY_TABLE\W"
r"\WYOUR_TABLE\W"
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
eautifulSoup, etc.
> HTMLParser works fine for me, but I am looking for a good
> tutorial to learn it nicely.
Take a read of the topic "Parsing, creating, and Manipulating
HTML Documents" from chapter five of Text Processing in Python.
http://gnosis.cx/TPiP/chap5.txt
--
Neil Ceru
maskit in this file and also
> need to print Sometext above it..SOmetext location can vary as
> you can see above.
>
> In the first instance it is 3 lines above mask it, in the
> second instance it is 4 lines above it and so on..
>
> Please help how to do it?
How can you te
>
> if is_sometext(line):
> memory = line
>
> if line == 'maskit':
> print memory
Tobiah's solution fits what little we can make of your problem.
My feeling is that you've simplified your question a little too
much in hopes that it would help us provide a better solution.
Can you provide more context?
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
c destruction. It wouldn't
buy much except for namespace tidyness.
for x in range(4):
print(x)
print(x) # Vader NOoOO!!!
Python provides deterministic destruction with a different
feature.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-07-05, Chris Angelico wrote:
> On Fri, Jul 5, 2013 at 11:24 PM, Neil Cerutti
> wrote:
>> Python provides deterministic destruction with a different
>> feature.
>
> You mean 'with'? That's not actually destruction, it just does
> one of the same j
the methods you
will need.
To find clusters and min and max values you will likely need to
put the datetime objects in a list, and use some Python builtins
and list methods.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-07-07, Steven D'Aprano wrote:
> On Fri, 05 Jul 2013 13:24:43 +0000, Neil Cerutti wrote:
>
>> for x in range(4):
>>print(x)
>> print(x) # Vader NOoOO!!!
>
> That loops do *not* introduce a new scope is a feature, not a bug. It is
> *real
d
just reset it to factory defaults and reconfigure.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
That's the system I've adopted. I use the mouse lefty all day
when working and righty all night when playing.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ementors: thwarting
hexdumping cheaters and cramming their games onto microcomputers
with one blow.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ine spec was never
officially published either. I believe a "task force" reverse
engineered it sometime in the 90's.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
boxes of router's web login
>> interface?
>
> It certainly could. It's just simple HTTP requests, which Python
> handles admirably. But this request was sent by a spambot and doesn't
> need a response.
FRANK DREBBIN
Yes... I know that. Now.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
hains are an advanced technique you could introduce, but
you'd need a huge list of names broken into syllables from
somewhere.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-07-17, Chris Angelico wrote:
> On Wed, Jul 17, 2013 at 11:20 PM, Neil Cerutti wrote:
>> Markov chains are an advanced technique you could introduce, but
>> you'd need a huge list of names broken into syllables from
>> somewhere.
>
> You could use names br
set again.
Thanks to the set-like view of dict.keys it worked just like one
might hope.
Looking at it again "seen" might be a redundant parallel version
of students.keys().
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
1a) Does it work?
1b) Can you prove it?
It's best to at least have some regression tests before you start
refactoring and optimizing.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
chess positions showed that they were powerfully accurate when
shown positions from real games, but no better than the average
schmoe when shown randomly positioned pieces. So if everyone
basically follows PEP8 we all benefit from playing by the same
game rules, as it were.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
("status", 3141, "Status code from ISO-3.14159"),
> ...
> ):
> do_something(name, value)
> print(description)
>
> which does give some modest readability benefits, but at a
> creation cost I personally am unwilling to pay.
I'm actually OK with the creation cost, but not the maintenance cost.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
otocol when the format and shape are also equal. The
database must be returning chunks of binary data in a different
shape or format than you are writing it.
Perhaps psycopg2 is returning a chunk of ints when you have
written a chunk of bytes. Check the .format and .shape members of
the return va
WS!
>
> Why "poor", Ralph?
>
> I am poor in the essence of ignorance's bliss, rich only in the
> never-ending thirst for knowledge and more languages. In me there meet
> a combination of antithetical elements which are at eternal war with
> one another... I
; service_num_list = [num for num in range(0,5)]
service_num_list = list(range(5))
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-09-14, Chris Angelico wrote:
> But then again, who actually ever needs fibonacci numbers?
If it should happen that your question is not facetious:
http://en.wikipedia.org/wiki/Fibonacci_number#Applications
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
is 0. The function tried to add 'r' to 0.
That said:
>>> sum('rtarze', '')
Traceback (most recent call last):
File "", line 1, in
TypeError: sum() can't sum strings [use ''.join(seq) instead]
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
x27;.join(sequence). To add floating point values with
extended precision, see math.fsum(). To concatenate a series of
iterables, consider using itertools.chain().
Are iterables and sequences different enough to warrant posting a
bug report?
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
e last one. Also, be sure
to check itertools for occasionally for cool stuff like this.
>>> for values in itertools.product(range(3), repeat=2):
... print(values)
...
(0, 0)
(0, 1)
(0, 2)
(1, 0)
(1, 1)
(1, 2)
(2, 0)
(2, 1)
(2, 2)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
d tuple(grouper(item) for item in zip(*accum))
break
yield tuple(grouper(item) for item in zip(*accum))
The interface could stand improvement. I find the grouper
argument very convenient, but none of the other grouping
iterators find it needful. Forcing n to be a keyword argument is
unfortunate as well.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
and it makes printouts easy to create.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
oices
of algorithm and implentation.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
int a fixed number of digits after the decimal
point, so it won't do want Adrien wants.
Adrien, you will need to do some post-processing on fixed point
output to remove trailing zeroes.
>>> print("{:.2f}".format(2.1).rstrip('0'))
2.1
>>> print("{:.2f}".format(2.127).rstrip('0'))
2.13
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
h
arithmetic:
def is_palindrom(n):
s = str(n)
return s = s[::-1]
> Here's some timing results using Python 2.7:
Excellent work.
You can of course drop to C for arithmetic and likely triumph
over Python strings. That's never been applicable for me, though.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-10-25, Neil Cerutti wrote:
> Try defeating the following with arithmetic:
>
> def is_palindrom(n):
>s = str(n)
>return s = s[::-1]
Sorry for the typos. It should've been:
def is_palindrome(n):
s = str(n)
return s == s[::-1]
--
Neil Cerutti
--
ht
On 2012-10-25, Ian Kelly wrote:
> On Thu, Oct 25, 2012 at 2:00 PM, Neil Cerutti
> wrote:
>> Yes indeed! Python string operations are fast enough and its
>> arithmetic slow enough that I no longer assume I can beat a
>> neat lexicographical solution. Try defeating the foll
em, and two solutions. Solution 1 has downside
> A, and solution 2 has downside B. If he complains about
> downside A, you say, well, use solution 2. If he complains
> about downside B, you say, well, use solution 1.
>
> What if he wants to avoid both downsides A and B? What solution
> does he use then?
You abandon the while loop and compose a generator.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
if tag == 'html':
print rec
elif tag == 'csv':
writer.writerow(rec)
else:
raise ValueError("Unknown record type %s" % tag)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ize(tar_file) >= limit:
> close(tar_file)
> tar_file = new_tar_file()
>
I have not used this module before, but what you seem to be
asking about is:
TarFile.gettarinfo().size
But your algorithm stops after the file is already too big.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
hat
most others can't, .e.g, Chris Sawyer. But, as Louis Moyse, a
great musician remarked: "Without hard work, talent means
nothing."
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
rb, but since it's also a well-used noun it's
perhaps not quite as good as send.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
uence of "elements" starting at "1",
> using "distance" as the spacing, until you exceed "n", and you
> want to produce a "sum" of all those elements...
This one's sort of a trick question, depending on your definition
of "trick". The most obvious implementation is pretty good.
In both cases a web search and a little high-density reading
provides insights and examples for the OP.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
little better, but
difflib finds some stuff that it misses.
In your case, the name is munged horribly in one of the files so
you'll first have to first sort it out somehow.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
for rows, row in enumerate(names):
...though I would find 'rownum' or 'num' or just 'i' better than
the name 'rows', which I find confusing.
> name_find()
> ofile = open('c:/Working/ttest.csv', "wb")
> writer = csv.writer(wfile, delimiter=';')
> for insert in namelist:
> writer.writerow(insert)
> wfile.close()
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-11-30, subhabangal...@gmail.com wrote:
> Python has one textming library, but I am failing to install it
> in Windows. If any one can kindly help.
More information needed.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
To also index them:
vbdix = [i for i, a in emumerate(l) if a[1] == 'VBD']
vbdno = len(indices)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
> There's a built-in that does "reduce(operator.add"; it's called "sum":
>
>>>> sum(a, ())
> (1, 2, 3, 4)
I thought that sort of thing would cause a warning. Maybe it's
only for lists.
Here's the recipe from the itertools documentation:
(x[4])
But do you really need to save the whole file in a list first?
You could simply do:
for record in csvreader:
if len(record) >= 4:
sku.append(record[4])
Or even:
sku = [record[4] for record in csvreader if len(record) >= 4]
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
y way that felt shorter or more pythonic:
I'm really tempted to import re, and that means takewhile and
dropwhile need to stay. ;)
But seriously, this is a quick implementation of my first thought.
description = s.lstrip(string.ascii_uppercase + ' ')
product = s[:-len(description)-1]
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-12-04, Nick Mellor wrote:
> Hi Neil,
>
> Nice! But fails if the first word of the description starts
> with a capital letter.
Darn edge cases.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
FIFTY TWO Chrysler LeBaron.")
['CAR FIFTY TWO', 'Chrysler LeBaron.']
>>> prod_desc("MR. JONESEY Saskatchewan's finest")
['MR. JONESEY', "Saskatchewan's finest"]
"""
i = 0
while
ble.
I'm struggling with the empty description bug right now. ;)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
;NO DESCRIPTION")
['NO DESCRIPTION', '']
"""
prod = ''
desc = ''
for k, g in itertools.groupby(s.split(),
key=lambda w: any(c.islower() for c in w)):
a = ' '.join(g)
if k:
desc = a
else:
prod = a
return [prod, desc]
This has no way to preserve odd white space which could break
evil product name differences.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-12-05, Ian Kelly wrote:
> On Wed, Dec 5, 2012 at 7:34 AM, Neil Cerutti wrote:
>> Well, shoot! Then this is a job for groupby, not takewhile.
>
> The problem with groupby is that you can't just limit it to two groups.
>
>>>> prod_desc("CAPSICUM RE
be in function loading time...
> I'll check ceval.c
>
> However, isn't there a room for a slight optim here? (in this case, the
> dead code is obvious, but it may be hidden by complex loops and
> conditions)
Maybe it's the difference between LOAD_CONST and LOAD_GLOBAL. We
can wonder why g uses the latter.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
rod = []
desc = []
for k, g in itertools.groupby(s.split(),
key=lambda w: any(c.islower() for c in w)):
if prod or k:
desc.extend(g)
else:
prod.extend(g)
return [' '.join(prod), ' '.join(desc)]
--
Neil Cerut
eaks the latest groupby.
A-ha! I did check your samples for the case of an empty product
name and not find any started to think it couldn't happen.
Change
if prod or k:
to
if desc or prod or k:
If this data file gets any weirder, let me know. ;)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-12-05, Vlastimil Brom wrote:
> ... PARSNIP, certified organic
I'm not sure on this one.
> ('PARSNIP', ', certified organic')
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
f *not* creating that stupid list_of_strings.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2012-12-07, Steven D'Aprano wrote:
> On Thu, 06 Dec 2012 13:51:29 +0000, Neil Cerutti wrote:
>
>> On 2012-12-06, Steven D'Aprano
>> wrote:
>>> total = 0
>>> for s in list_of_strings:
>>> try:
>>> total += int(s)
>
is working correctly it looks like this:
else:
raise SomeException("{} can't happen!".format(the_context))
else: raise exception constructs have saved me a lot of time.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
or Vim that will allow simple
reindenting and a bunch of other cool cursor movement powers I
don't even use. ctags will also work, though I've never really
needed it.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
lt
indespensable. But even though I can do the same with Python, it
doesn't feel crucial when writing Python. The errors are more
few. ;)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
are checked. Working to make a solution that's
complete and extensible yields the most educational benefits, I
think.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
ttp://www.diveintopython.net/
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
On 2013-01-24, John Gordon wrote:
> In Sharwan Joram
> writes:
>
>> use vim.
>
> He said he wanted autocomplete. Does Vim have that?
Yes, you use its ctags support to get it working, I believe.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
> know Python.
I agree.
Vim is great, Emacs is great. I'm glad I know one of them. But
learning one of them is as project unto itself. So selecting
either just for Python is skipping too many decisions and maybe
biting off too big a piece of the snake.
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
know what the situations are where you want
> the behaviour of atoi().
Right. atoi is no good even in C. You get much better control
using the sprintf family. int would need to return a tuple of the
number it found plus the number of characters consumed to be more
useful for parsing.
>>>
On 2013-01-25, Hans Mulder wrote:
>> Right. atoi is no good even in C. You get much better control
>> using the sprintf family.
>
> I think you meant sscanf.
Yes, thanks for knocking that huge chunk of rust off of me. ;)
--
Neil Cerutti
--
http://mail.python.org/mailman/listinfo/python-list
1 - 100 of 1188 matches
Mail list logo