Search code examples
pythonpython-3.xsublimetext3

Basic addition of integers won't print in Sublime Text 3?


If I do a simple

print('hello world')

sublime text will show the output as normal. However, if I do:

28 + 7

it wont show anything. Not an error message or anything, its just blank.

I am making sure to use the correct build system, and I save my files with a .py to make sure they are running in python code. I have been using Sublime text for days now with no issues. The only thing I changed recently was installing 'pip' upon the advisory of "Automate the Boring Stuff with Python". I did this carefully and pip installed normally as well.

Can someone help me figure out what's going on?


Solution

  • To get output in Sublime Text 3 text editor or IDE

    You have to provide print(28+7) in your python file

    eg:

    In file.py file write below two line and save it.And run using Ctrl+b

    print("Hello World")

    print(28+7)