0
Why fgets() in cpp not terminate on enter key
This is code related to remove punctuation marks From string. https://code.sololearn.com/cGtsgm3MsFI0/?ref=app
2 Answers
+ 2
Gaurav,
Why are you using char[] and fgets() in C++? why not use std::string and std::getline()? char[] and fgets() are for C codes bro.
0
But why fgeta() not terminating on the '\0' (null) character.
When i am enter, enter key then also it keep taking value.
Pls help me...
https://code.sololearn.com/cGtsgm3MsFI0/?ref=app