Path: csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail From: Erik Newsgroups: comp.lang.python Subject: Re: i cant seem to figure out the error Date: Sun, 3 Apr 2016 21:10:51 +0100 Lines: 18 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: news.uni-berlin.de M4cEng0cF2Pl4lQQDR+T4AQCx7xs2z/plCQ6NOkAk0Dg== Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.005 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'debug': 0.04; 'assignment': 0.07; 'subject:error': 0.11; 'accordingly.': 0.13; 'result.': 0.15; 'assignment.': 0.16; 'carefully.': 0.16; 'from:addr:python': 0.16; 'received:84.93': 0.16; 'received:84.93.230': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'withdrawal': 0.16; 'wrote:': 0.16; 'to:2**1': 0.21; 'code.': 0.23; 'written': 0.24; 'header:In-Reply- To:1': 0.24; 'header:User-Agent:1': 0.26; 'least': 0.27; 'attempting': 0.29; 'lot.': 0.29; 'code': 0.30; 'error.': 0.31; 'received:84': 0.32; 'list': 0.34; 'done': 0.35; 'quite': 0.35; 'but': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'method': 0.37; 'does': 0.39; 'subject:the': 0.39; 'takes': 0.39; 'received:192': 0.39; 'to:addr:python.org': 0.40; 'still': 0.40; 'called': 0.40; 'your': 0.60; 'charset:windows-1252': 0.62; 'balance': 0.64 X-CM-Score: 0.00 X-CNFS-Analysis: v=2.1 cv=Iat6Ijea c=1 sm=1 tr=0 a=d6bQx1Csmutac+MnUcj9pQ==:117 a=d6bQx1Csmutac+MnUcj9pQ==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=N659UExz7-8A:10 a=whcJDcFaRUUdzXH69cEA:9 a=pILNOxqGKmIA:10 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 In-Reply-To: X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com comp.lang.python:106403 Hi Anthony, On 03/04/16 16:06, anthony uwaifo wrote: > please i need help with this assignment. I have written a code and i still > get an error. please help me debug my code. We see this assignment come up a lot. The "tutor" list is a better place to go, but well done for at least attempting it and coming up with quite a good result. > - Create a method called `withdraw` that takes in cash withdrawal amount > and updates the balance accordingly. if amount is greater than balance > return `"invalid transaction"` Read this carefully. Read it _literally_. What does your 'withdraw' method return? E.