diff --git a/README.md b/README.md index bb11005..da5b7f6 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,9 @@ Include soi and you're ready to go! - disables output buffering - checks whether all input has been read - removes evil functions from the standard library such as new and printf. +- defines int to 64 bit + +The header requires at least C++11. ## Configuration @@ -25,7 +28,7 @@ this check using `SOI_EOFCHECK=1`. ## Template Using this header is as simple as: -``` +```c++ #include signed main() { @@ -33,4 +36,24 @@ signed main() { } ``` -It requires at least c++11 to function. +## Example +See example.cpp for a larger example. + +```c++ +#include +signed main() { + dbg("hi"); + vector pi{3,1,4,1,5,9,2,6}; + dbg(pi); + int x=4; + dbg(x+3); +} +``` + +prints: + +``` +[test.cpp:3 (main)] hi +[test.cpp:5 (main)] pi = [3, 1, 4, 1, 5, 9, 2, 6] (vector) +[test.cpp:7 (main)] x+3 = 7 (long int) +```