北京高考改革新方案,醉倒草丛误被击毙,2014上海事业单位养老金
sublime编辑模式下,编译py文件,enter键后并没有打印,发现是sublime编译方式的问题,需要安装插件sublimerepl。
#!/usr/bin/python3 str = input("请输入: ") print(str)
安装完之后,点击tool--sublimerepl-- python-- python - run current file,就可以正常的编译,输入一行后打印
由于每次编译都需要这步操作,会很麻烦,可以设置快捷键:
点击preferences--key bindings,设置快捷键,本次设置的是f5,可以自行修改
[ {"keys": ["f5"],"command": "repl_open", "caption": "python - run current file", "id": "repl_python_run", "mnemonic": "r", "args": { "type": "subprocess", "encoding": "utf8", "cmd": ["python", "-u", "$file_basename"], "cwd": "$file_path", "syntax": "packages/python/python.tmlanguage", "external_id": "python", "extend_env": {"pythonioencoding": "utf-8"} } } ]
以上这篇sublime python3 输入换行不结束的方法就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持移动技术网。
如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复
新手学习Python2和Python3中print不同的用法
Python基于os.environ从windows获取环境变量
网友评论