Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 81947

Python is a general-purpose, dynamically typed, object-oriented high-level programming language. Interpreters for versions 3.x and 2.x come installed on the Raspberry Pi's most popular operating system distributions.

2 votes
1 answer
3k views

Python code runs in Thonny correctly but does not work in terminal

I have a code that gets a one or a 0 from the user and will turn an LED on if 1, off if 0. It runs perfect when I run it in the Thonny IDE on the Pi itself. But when I try to run it through putty or e …
dka13's user avatar
  • 163
1 vote
Accepted

Python code runs in Thonny correctly but does not work in terminal

I have figured it out. For some reason in the IDE the keyboard input is received as a string, where as in the terminal it is received as an int. So i just needed to make the line like the following to …
dka13's user avatar
  • 163