0

I wrote a simply program:

print "What is your name?"
name = raw_input()
print "Hello %s!" % name 

When I run it directly in VIM I get:

What is your name? Hello print "What is your name?"!

I can't type anything. Program stops with "Hit any key to close this window..." What is going here? Python 2.7, Win10, VIM 7.4.

mechanical_meat
  • 163,903
  • 24
  • 228
  • 223
jundymek
  • 1,013
  • 4
  • 18
  • 40
  • Which vim command are you using to run it? – cdarke Jul 17 '16 at 21:58
  • :w !python - I have F5 shortcut in my _vimrc file. When I type this command in VIM console I get an error: "What is your name? Traceback (most recent call last): File "", line 2, in EOFError: EOF when reading a line shell returned 1" – jundymek Jul 17 '16 at 22:00
  • 2
    Do you understand what `:w !python` does? – Sato Katsura Jul 18 '16 at 05:06

0 Answers0