I'm having a little trouble with itoa(). Can some one please show me a little example of how to use it.
What I'm trying to do is make a 6 character string based on the time. Here is what I have:
I know I must be calling itoa function wrong but I'm not really sure how. Also can anyone explain the radix value to me? Or at least what value it should be.Code:#include <dos.h> main() { struct time t; char name[2]; int result; gettime(&t); result=itoa(t.ti_hour,name,0); printf("%s",result); }
Thanks alot,
Thantos



LinkBack URL
About LinkBacks


