0
print "entry the news:"
news = sys.stdin.readline() 

I copy paste news entry and the program just run my first line news, not the other. I've searched it for many times but there were no sites can answer my problem. I'm using Python 2.7

DYZ
  • 55,249
  • 10
  • 64
  • 93
  • Use `news = raw_input("entry the news:")` _in a loop_. – DYZ Jul 23 '18 at 23:26
  • How many lines do you think that sys.stdin.readline() reads? (For instance just by looking at the name) – Ronald Jul 23 '18 at 23:26
  • `readline()` means "read one line". If that's not what you want, don't call that function. Maybe you meant `read()`, which means "read as much as possible", and will give you one big multi-line string. Or maybe you wanted to loop over all the lines, like `for news in sys.stdin:`, which will give you one line at a time. Or… maybe you wanted something different, but then you'll have to explain what you want. – abarnert Jul 23 '18 at 23:26

0 Answers0