Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!eweka.nl!lightspeed.eweka.nl!194.134.4.91.MISMATCH!news2.euro.net!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.034 X-Spam-Evidence: '*H*': 0.93; '*S*': 0.00; 'string': 0.09; '-10': 0.09; 'ascii': 0.09; 'converts': 0.09; 'bye': 0.16; 'subject:non': 0.16; 'with?': 0.16; 'print': 0.22; 'characters': 0.30; 'message- id:@mail.gmail.com': 0.30; 'guess': 0.33; 'subject:with': 0.35; 'received:google.com': 0.35; 'thank': 0.38; 'to:addr:python-list': 0.38; 'to:addr:python.org': 0.39; 'how': 0.40; 'read': 0.60; 'more': 0.64; 'dealt': 0.91 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=J1Trt+V201adLys2hTjE5Yw6atCFAFM1YfLruyZRbI0=; b=Qvx46CkU0dk1gxDpYvwpm7GXKzyJmelefPQouhkRThPuLFCZZxaG1Iwk7K1tkZX78E kYA+pX9FKdSXYLvZdufF43NtnKpmejae9oosGkDuChBa4v64ewzE1ICSrKygzXzQemrF rGlvFoF7e8ddJPrdI5qHCHH9jslnHxE1k/6A11eXsVScc7K9SezljqYy3O6Q6LYzNh5g yTPiaSxWsD4yg3oFbTWUMZNieKMRmnOF2gK6TC+wBsKmoUuVEzrZowbvzex1ztpKtEZb fqNOX3w05GRFs6DZtmxstQaLRcWqdpA+WFqpRd2QLSYXLKYldLBgLYs1wrsYBmlDpEhM xv8g== X-Received: by 10.112.142.66 with SMTP id ru2mr10548828lbb.7.1372618011784; Sun, 30 Jun 2013 11:46:51 -0700 (PDT) MIME-Version: 1.0 From: Andrew Z Date: Sun, 30 Jun 2013 14:46:11 -0400 Subject: math functions with non numeric args To: python-list@python.org Content-Type: multipart/alternative; boundary=001a11c37aaa013dd004e063891e X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 27 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1372618018 news.xs4all.nl 15868 [2001:888:2000:d::a6]:53043 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:49506 --001a11c37aaa013dd004e063891e Content-Type: text/plain; charset=ISO-8859-1 Hello, print max(-10, 10) 10 print max('-10', 10) -10 My guess max converts string to number bye decoding each of the characters to it's ASCII equivalent? Where can i read more on exactly how the situations like these are dealt with? Thank you AZ --001a11c37aaa013dd004e063891e Content-Type: text/html; charset=ISO-8859-1
Hello,

print max(-10, 10)
10
print max('-10', 10)
-10

My guess max converts string to number bye decoding each of the characters to it's ASCII equivalent?

Where can i read more on exactly how the situations like these are dealt with?

Thank you
AZ

--001a11c37aaa013dd004e063891e--