+ 2

Why am i not able to run my code?

i have added cin.get(line,MAX,'\n'); to my code but it doesn't asks me for an input... while the code works perfectly when i replace it with cin>>line; ... what's the issue? https://code.sololearn.com/cb5R2USeuSlg/?ref=app

2nd Jan 2018, 8:52 PM
Vedant Sharma
Vedant Sharma - avatar
3 Answers
+ 3
https://www.sololearn.com/discuss/974706/?ref=app See this post for some info on how to get cin.get() to read input.
3rd Jan 2018, 4:23 AM
Solo Wanderer 4315
Solo Wanderer 4315 - avatar
+ 8
all is fine! sololearn input is a bit special
2nd Jan 2018, 8:58 PM
Oma Falk
Oma Falk - avatar
0
Seems fine to me.
2nd Jan 2018, 9:54 PM
josh mizzi
josh mizzi - avatar