Im new to this please help | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Im new to this please help

So I've been using the SoloLearn website and also on my phone, I'm extremely interested in learning programming and an open to any and all wisdom that can possibly be shared with me, my question right now is; if I'm running Python 3.5 and SoloLearn in a divided window, how do I command Python to run my input? I.E. x=4 if x==5: print("true") else: print("false") How do I run it or command the answer>

24th Dec 2016, 9:45 PM
Dan
Dan - avatar
4 Answers
+ 2
Welcome! Anytime you want, you can use the handy SoloLearn "Code Playground" that can be found at https://code.sololearn.com/#JUMP_LINK__&&__python__&&__JUMP_LINK to write and test your own code. You can simply copy and paste what you have, and select the run button at the bottom for the code you wrote to run on the screen on the right. If you ever have issues with the "Code Playground" or just want to run your code on your own PC, you can create a new .py file and run it. These are the directions for one way to do it one Windows OS: 1. You can use a text editor such as Notepad++ or Notepad (Notepad is built in on Windows). There are plenty of different text editors you can use, the more advanced codes you write, the more you'll experience. Copy and paste the lines of code into the document. Save the file as a .py file (Make sure to set the "Save as type" to all files). An example: Example.py . Be sure to remember where you save it. 2. Once you have saved it, open up the IDLE (Python GUI) by searching it. On the task-bar at the top, select "Open", and find your .py file, in my case, I would open up the Example.py file. 3. After a new window appears, go to the task-bar at the top and select "Run", then "Run Module", or press the f5 button on your keyboard. Your code should run on IDLE. Hope this helps.
24th Dec 2016, 10:40 PM
Harry H
Harry H - avatar
+ 1
are you using CMD or idle? the code right there should be running fine.
24th Dec 2016, 10:25 PM
kallzo
kallzo - avatar
+ 1
Do you have a different IDE?
24th Dec 2016, 10:36 PM
kallzo
kallzo - avatar
0
i think idle
24th Dec 2016, 10:27 PM
Dan
Dan - avatar