fgets vs getline: Which Function to Use and Why
Jan 14 · 2 min read · Both methods are used to take input in C++, and we can use either one. But why do we need a distinction between these two methods? The reason is that when we use fgets, we can see how memory is allocated. To understand this more clearly, let's look a...
Join discussion