Re: Problem with 'print'

2016-01-09 Thread D'Arcy J.M. Cain
On Sat, 9 Jan 2016 12:40:16 +0100 pablo gormi wrote: > Hello, recently I downloaded python, but when I try to execute one > file with the command 'print' it shows me a error. The error is: > > Missing parentheses in call to 'print' You downloaded Python 3. but your script was written for Python

Re: Problem with 'print'

2016-01-09 Thread Peter Otten
pablo gormi wrote: > Hello, recently I downloaded python, but when I try to execute one file > with the command 'print' it shows me a error. The error is: > > Missing parentheses in call to 'print' > > Please help mThank you. You have downloaded Python 3 and are using Python 2 syntax. Learnin

Re: Problem with 'print'

2016-01-09 Thread Chris Angelico
On Sat, Jan 9, 2016 at 10:40 PM, pablo gormi wrote: > Hello, recently I downloaded python, but when I try to execute one file > with the command 'print' it shows me a error. The error is: > > Missing parentheses in call to 'print' The error is telling you what you need to do. Put parentheses arou

Re: Problem with print and output to screen

2012-12-11 Thread Mike
El martes, 11 de diciembre de 2012 20:07:09 UTC-3, Joel Goldstick escribió: > On Tue, Dec 11, 2012 at 6:00 PM, Dave Angel wrote: > > > On 12/11/2012 05:53 PM, Joel Goldstick wrote: > > > When you read the file line by line the end of line character is included > > > in the result > > > > >

Re: Problem with print and output to screen

2012-12-11 Thread Joel Goldstick
On Tue, Dec 11, 2012 at 6:00 PM, Dave Angel wrote: > On 12/11/2012 05:53 PM, Joel Goldstick wrote: > > When you read the file line by line the end of line character is included > > in the result > > > > try user[:-1] instead to strip the return from your printed text > > > > The catch to that is

Re: Problem with print and output to screen

2012-12-11 Thread Dave Angel
On 12/11/2012 05:53 PM, Joel Goldstick wrote: > When you read the file line by line the end of line character is included > in the result > > try user[:-1] instead to strip the return from your printed text > The catch to that is the last line in the file might not have a newline. In that case, w

Re: Problem with print and output to screen

2012-12-11 Thread Joel Goldstick
When you read the file line by line the end of line character is included in the result try user[:-1] instead to strip the return from your printed text On Tue, Dec 11, 2012 at 5:31 PM, Mike wrote: > Hello, I am learning python and i have the next problem and i not > understand how fix. > The

Re: Problem with print and output to screen

2012-12-11 Thread Dave Angel
On 12/11/2012 05:31 PM, Mike wrote: > Hello, I am learning python and i have the next problem and i not understand > how fix. > The script is very simple, shows in the terminal the command but, the row is > divided in two: > Example: > > > /opt/zimbra/bin/zmprov ga u...@example.com > |egrep "(z