#Why is "getline" command have red under it?
14 messages · Page 1 of 1 (latest)
Hover your mouse on it to see what's wrong.
Try including the string header and see if that solves the problem.
idk what that is ðŸ˜
getline() comes from the string header, just like cin/cout comes from iostream.
On line 3, do:
#include <string>
See if that solves the problem.
Correctly as Torrman says, include the Standard Library Header called string to be able to use the getline function. when you include something you open up to new functionality in the program.
By writing
#include <string>
On line 3..
You now have the ability to use getline from the std:: (standard library)
You can read more about the string header here https://en.cppreference.com/w/cpp/string
@worthy scarab has reached level 6. GG!
alright
thanks