How to handle unknow size user input in C Here are two examples to handle user input in C. 1. scanf This method is easy get attack by buffer overflow, try input some characters which are more than what you declare to experience about what is buffer overflow. 2. fgets This method can protect buffer overflow by limit the character user input. However, above two methods only can handle normal user input, how about i want to handle user input with 1000 or even more characters? How to handle unknow size user input in C
How To: C / C++ Main
This variable is set by major modes, as a buffer-local variable, to specify how to fontify text in that mode. The value should look like this: The first element, , indirectly specifies the value of font-lock-keywords. It can be a symbol, a variable whose value is the list to use for font-lock-keywords. It can also be a list of several such symbols, one for each possible level of fontification. GNU Emacs Lisp Reference Manual GNU Emacs Lisp Reference Manual
Bjarne Stroustrup's Homepage Morgan Stanley | Columbia University | Texas A&M University home | C++ | FAQ | technical FAQ | C++11 FAQ | publications | TC++PL | Tour++ | Programming | D&E | bio | interviews | applications | glossary | compilers I'm a Managing Director in the technology division of Morgan Stanley in New York City, a Visiting Professor in Computer Science at Columbia University, and a Distinguished Research Professor in Computer Science at Texas A&M University. I designed and implemented the C++ programming language. To make C++ a stable and up-to-date base for real-world software development, I stuck with its ISO standards effort for 20+ years (so far). Writings:

Bjarne Stroustrup's Homepage

Boost C++ Libraries Boost provides free peer-reviewed portable C++ source libraries. We emphasize libraries that work well with the C++ Standard Library. Boost libraries are intended to be widely useful, and usable across a broad spectrum of applications. The Boost license encourages both commercial and non-commercial use. We aim to establish "existing practice" and provide reference implementations so that Boost libraries are suitable for eventual standardization. Ten Boost libraries are included in the C++ Standards Committee's Library Technical Report (TR1) and in the new C++11 Standard.

Boost C++ Libraries

The essential tools needed to follow these tutorials are a computer and a compiler toolchain able to compile C++ code and build the programs to run on it. C++ is a language that has evolved much over the years, and these tutorials explain many features added recently to the language. Therefore, in order to properly follow the tutorials, a recent compiler is needed. It shall support (even if only partially) the features introduced by the 2011 standard. Many compiler vendors support the new features at different degrees. cPlusPlus cPlusPlus