Below is the screenshot of code snippet from stdio.h
Below is the attachment of my stdio.h file which is Pelles C file.
stdio.h
Please look at it and help me find out where is printf!!
All I see is declaration and no ACTUAL FUNCTION BODY!!
Below is the screenshot of code snippet from stdio.h
Below is the attachment of my stdio.h file which is Pelles C file.
stdio.h
Please look at it and help me find out where is printf!!
All I see is declaration and no ACTUAL FUNCTION BODY!!
The function would likely be compiled into a library already, so you won't find sourcecode for it. I don't know how Pelles C does things, and had no luck finding its source code (the implementation might be closed source).
_CRTCHK is likely a macro defined elsewhere, maybe to reduce repetitive typing and to allow changes in a single place to propagate to many headers/function declarations. I'm not much of a C guy, so someone else can explain this much better.
Libraries are pre-compiled code that you can link with your program (most prominently libc). This way, you don't need to (re)compile everything yourself when writing a C program. You just include the header files into the code you write and the linker later combines the library code (e.g. the implementation of printf) with yours. Dynamic linkage also allows you to switch out the library for a different version (e.g. a newer one with fixed bugs) without touching your program at all!
Last edited by Guest; 11-28-2017 at 05:28 AM. Reason: typo
Ok Thanks Adrian. I'm a simple young adult 20 years old , dropped out of college with a will to learn programming. I earn very less , so all I learn is from you guys , don't have money to buy many books , so I'm trying to grab C in my belt to the extreme point so that I can apply for a programmer job and move forward. You guys are my only guide.
If you do know some C person , please refer me to him , I want to learn more. Thanks Sir
In the 21st century, a lot of information (even good one) is free so lack of money doesn't have to keep you from learning. Look for free online courses on sites like edx.org, I suspect those are of good quality too.
I used one book (for C++ in my case) and the rest I learned from documentation and other users.
What I would strongly encourage though is that you start using a Linux system, because C is much more at home there, and it's conductive to programming in general. The user base is also far more geared towards these things so resonance/critique/help is easily gotten.
Right now few registered users are online. Later today people will show up that know this stuff, so all you can do is wait. Also consider IRC chat, like ##C on freenode, where you may get quicker answers.If you do know some C person , please refer me to him , I want to learn more.
Last edited by Guest; 11-28-2017 at 06:20 AM.