+ 2
You should stick with C++ input and output streams(cin,cout,cerr) they're way safer than C style input/output mechanisms...
If your a C++ beginner, i recommend reading "Beginning C++17"...
You can download it at "allitebooks.in", you'll learn alot about C++..