Comments on your code inline below.
On Sat, Jul 06, 2013 at 02:38:27PM -0700, Jim Mooney wrote:
> import sys
>
> # Data
> ones = {'1': 'one', '2': 'two', '3': 'three', '4': 'four', '5': 'five',
> '6': 'six', '7': 'seven', '8': 'eight', '9': 'nine'}
>
> tens = {'2': 'twenty', '3': 'thirty', '4'
On 8 July 2013 00:12, Steven D'Apranocatching ArithmeticError
> further on), please use a custom exception
>
Well, an Arithmetic Error was better than bubbling up to a totally general
one. I'm not sure how do custom error code. Short example, please ;')
Jim
__
On 07/08/2013 01:57 PM, Jim Mooney wrote:
On 8 July 2013 00:12, Steven D'Apranocatching ArithmeticError
further on), please use a custom exception
Well, an Arithmetic Error was better than bubbling up to a totally general
one. I'm not sure how do custom error code. Short example, please ;')
> To make a custom error, first pick another error that's a superset of what
> you're doing. Then simply derive your error class from it. As a minimum:
>
> class TooHugeError (ValueError):
> pass
>
> Actually, I didn't get to classes yet since I wanted to nail procedural -
I'm in no rush - bu
On 07/07/13 22:57, Justin Chiu wrote:
What is the best approach to writing a concurrent daemon that can
execute callbacks for different types of events (AMQP messages, parsed
output of a subprocess, HTTP requests)?
Given nobody replied to your previous request I suggest you try another
forum.
On 07/08/2013 04:51 PM, Albert-Jan Roskam wrote:
haha, I hadn't even noticed the 'speling eror'. I was just thinking 'what the
heck is a desert spoon'? ;-)
"A dessert spoon is a spoon designed specifically for eating dessert and
sometimes used for soup or cereals."
On the other hand,
On 08/07/13 21:51, Albert-Jan Roskam wrote:
I was just thinking 'what the heck is a desert spoon'? ;-)
It's the one half-way between a teaspoon and a tablespoon :-)
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
___
Tuto
On Mon, Jul 8, 2013 at 1:51 PM, Albert-Jan Roskam wrote:
> haha, I hadn't even noticed the 'speling eror'. I was just thinking 'what
> the heck is a desert spoon'? ;-)
>
Many years ago, I saw this painted on the side of a pie shop:
"My favorite people are the people of the dessert", said Lawrenc
On 09/07/13 05:47, Dave Angel wrote:
On 07/08/2013 01:57 PM, Jim Mooney wrote:
On 8 July 2013 00:12, Steven D'Apranocatching ArithmeticError
further on), please use a custom exception
Well, an Arithmetic Error was better than bubbling up to a totally general
one. I'm not sure how do custom
On 09/07/13 05:59, Jim Mooney wrote:
To make a custom error, first pick another error that's a superset of what
you're doing. Then simply derive your error class from it. As a minimum:
class TooHugeError (ValueError):
pass
Actually, I didn't get to classes yet since I wanted to nail proc
10 matches
Mail list logo