C Books Guide and List
C++ Books Guide and List
Best Java Books

3,749 questions

4,049 answers

114 comments

10,705 users

What #include form should I use for standard library headers in c++?

0 votes
31 views
asked Jan 8, 2014 by smith Geek (15,340 points)

1 Answer

0 votes
The #include pre-processor directive is seen in three different forms for standard library header files:

#include "math.h"

#include <math.h>

#include <cmath>

1) The C++ specific header files were declared of the form <header>, dropping the earlier syntax of <header.h>

2) The C library files included in ANSI C++ were prefixed with the character 'c' and the .h suffix was dropped

3) The C library files included in ANSI C++ usually implement their functions as templates rather than macros.

4) All names in both sets of these files were placed within the std namespace
answered Jan 8, 2014 by rajesh Guru (39,140 points)

Related questions

0 votes
1 answer 17 views
17 views asked Jan 1, 2014 by smith Geek (15,340 points)
0 votes
1 answer 80 views
+1 vote
1 answer 25 views
0 votes
1 answer 13 views
13 views asked Jan 1, 2014 by sara Guru (24,570 points)
0 votes
1 answer 44 views
...