Thank you very much for your help.
Specification of error :
In python 2.7.3 for Ubuntu 12.04 32-bit
It creates a program with the following line of code :
Python is a programming language That lets you work more quickly and integrate your systems more effectively.
You can learn to use Python and see almost immediate gains in productivity and lower maintenance costs.
import math
elCociente def (x, y):
ratio = x / y
return ratio
theRemainder def (x, y):
remainder = x% y
return other
laRaiz def ( x ) :
root = math.sqrt ( x )
return root
LaSegRaiz def (y):
segraiz = math.sqrt ( y)
return segraiz
def main ( ) :
x = input (" Enter a number: " )
y = input (" Enter a second number :")
print " the quotient of dividing " , x , "with" , and , " is" , elCociente ( x , y)
print " the remainder of dividing " , x , " for " and , " is" , theRemainder ( x , y)
print " the root of " , x , " is" , laRaiz ( x )
print " the root ," and , " is" , LaSegRaiz ( y)
Where the lines 1 and 2 are not discussed , when compiling the program ( f5 ) warns us to a syntax error , open the sheel , we force the compilation typing the main and opens another blank shell . not saying that is the error line .
If commented lines 1 and 2 and compile again ( f5 ) jump several errors in the shell which can not close and forces us to have to kill python process .
I hope I have been much clearer .
thanks
Corrected with cometary Program
# Python is a programming language That lets you work more quickly and integrate your systems more effectively.
# You can learn to use Python and see almost immediate gains in productivity and lower maintenance costs.
import math
elCociente def (x, y):
ratio = x / y
return ratio
theRemainder def (x, y):
remainder = x% y
return other
laRaiz def ( x ) :
root = math.sqrt ( x )
return root
LaSegRaiz def (y):
segraiz = math.sqrt ( y)
return segraiz
def main ( ) :
x = input (" Enter a number: " )
y = input (" Enter a second number :")
print " the quotient of dividing " , x , "with" , and , " is" , elCociente ( x , y)
print " the remainder of dividing " , x , " for " and , " is" , theRemainder ( x , y)
print " the root of " , x , " is" , laRaiz ( x )
print " the root ," and , " is" , LaSegRaiz ( y) |