Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #60783

Re: Need help with programming in python for class (beginner level)

Date 2013-11-30 01:49 +0100
From Johannes Findeisen <mailman@hanez.org>
Subject Re: Need help with programming in python for class (beginner level)
References <e9d18514-1da5-471a-bf39-5f67d3d8fef7@googlegroups.com> <20131130013836.49f68d62@hanez.org>
Newsgroups comp.lang.python
Message-ID <mailman.3410.1385772643.18130.python-list@python.org> (permalink)

Show all headers | View raw


On Sat, 30 Nov 2013 01:38:36 +0100
Johannes Findeisen wrote:

> On Fri, 29 Nov 2013 16:31:21 -0800 (PST)
> farhanken@gmail.com wrote:
> 
> > print "<p>The total rolled was: "number" </p>"
> 
> The above line is wrong. You did it right below:
> 
> > print "<p>Thanks for playing, "  + name +  ".</p>"
> > print "<p>You bet the total would be at least " + value + ".</p>"
> 
> Do this:
> 
> print "<p>The total rolled was: " + number + " </p>"

Sorry, that was wrong! You need to convert to a string when
concatenating...

print "<p>The total rolled was: " + str(number) + " </p>"

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Need help with programming in python for class (beginner level) farhanken@gmail.com - 2013-11-29 16:31 -0800
  Re: Need help with programming in python for class (beginner level) Johannes Findeisen <mailman@hanez.org> - 2013-11-30 01:38 +0100
  Re: Need help with programming in python for class (beginner level) Eduardo A. Bustamante López <dualbus@gmail.com> - 2013-11-29 16:45 -0800
  Re: Need help with programming in python for class (beginner level) Johannes Findeisen <mailman@hanez.org> - 2013-11-30 01:49 +0100
  Re: Need help with programming in python for class (beginner level) Tim Chase <python.list@tim.thechases.com> - 2013-11-29 18:53 -0600
  Re: Need help with programming in python for class (beginner level) Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-11-30 00:59 +0000
  Re: Need help with programming in python for class (beginner level) Tim Chase <python.list@tim.thechases.com> - 2013-11-29 19:06 -0600
  Re: Need help with programming in python for class (beginner level) Mark Lawrence <breamoreboy@yahoo.co.uk> - 2013-11-30 01:08 +0000
  Re: Need help with programming in python for class (beginner level) Johannes Findeisen <mailman@hanez.org> - 2013-11-30 02:16 +0100
  Re: Need help with programming in python for class (beginner level) Julio Schwarzbeck <julio@techfuel.net> - 2013-12-01 17:01 -0800

csiph-web