Sep-01-2017, 06:33 PM
I have the following issue. I have this code:
def power(b, e):
result = b ** e
print " %d to the power of %d is %d." % (b,e,result)
power(37,2)
It is very simple one I know, but I am learning. I follow a course in codeacademy and this is one of the tasks. In codeacademy this code runs, with no errors. On my mac where I use Atom, the code runs as well. However on my windows (Visual Basic Code and Atom) it doesn't saying that there is an error on line 3 - point towards the end quote before the % (b,e,...
Does anyone know why the problem occurs?
I have python installed on both my Mac and PC, and I have included Python in the Path setting on my Windows machine.
Best Regards,
Tsvetan
def power(b, e):
result = b ** e
print " %d to the power of %d is %d." % (b,e,result)
power(37,2)
It is very simple one I know, but I am learning. I follow a course in codeacademy and this is one of the tasks. In codeacademy this code runs, with no errors. On my mac where I use Atom, the code runs as well. However on my windows (Visual Basic Code and Atom) it doesn't saying that there is an error on line 3 - point towards the end quote before the % (b,e,...
Does anyone know why the problem occurs?
I have python installed on both my Mac and PC, and I have included Python in the Path setting on my Windows machine.
Best Regards,
Tsvetan