Where can I find info on these

Started by
3 comments, last by xanin 19 years, 6 months ago
Ok I know that these are C functions but I did not know I would need to use them until I started messing with SDL. for instance printf = prints to screen I know that sprintf sscanf scanf %s = seems to be a normal variable inserted it place of this %d = seems to be a address inserted in place of this
My JournalComputer science education cannot make anybody an expert programmer any more than studying brushes and pigment can make somebody an expert painter. (Eric Raymond)"C makes it easy to shoot yourself in the foot. C++ makes itharder, but when you do, it blows away your whole leg."-- Bjarne Stroustrup
Advertisement
Check out Cone3D's C lessons. There are some explanations there. But for your convience, I will explain a few for you.

printf as you know prints to the screen. It's sorta the equivilent to cout.

scanf gets input. It's similar to cin.

%d and %s are used in printf and scanf. %d stands for integer and %s is a string. There is also %f with of course is a float. I think %d is a double as well. Thats as much as I can remember.
thanks alot I will check them out. I am using his sdl tutorials lol.
My JournalComputer science education cannot make anybody an expert programmer any more than studying brushes and pigment can make somebody an expert painter. (Eric Raymond)"C makes it easy to shoot yourself in the foot. C++ makes itharder, but when you do, it blows away your whole leg."-- Bjarne Stroustrup
It seems silly to supply the links when you can just as easily look it up on MSDN. But, here you go.

scanf and scanf format specifications
printf and printf format specifications
John BoltonLocomotive Games (THQ)Current Project: Destroy All Humans (Wii). IN STORES NOW!
As a side note if youre just learning C

if youve got money and you find yourself frequently asking yourself "how did i use this again?" or "what was the arg order here?" and youre like me and would rather not go google it and wade through all the python and perl pages that come up now, id highly reccomend grabbing a a copy of the K&R book (The C Programming Language by Kernighan and Ritchie)

This book I probably the most used book that I own actually, the thing practically falls open to page 250 now (string functions) given how often i forget argument orders

This topic is closed to new replies.

Advertisement