This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SPRINTF()

I am using SPRINTF() function and it increase the code by 2.3K. Is there any method to reduce the code size.

Thanks,

Mashood

Parents
  • "sprintf() is a very comprehensive and powerful function"

    It is indeed!

    Just look it up in any 'C' textbook, and you'll that it takes several pages just to describe all the formatting options!
    If you think you could implement all that functionality in significantly less than 2.3K, there's nothing to stop you having a try...!

    Probably easier to just implement the bit you actually need, though... ;-)

    You could start by looking for open-source implementations of atoi, etc

Reply
  • "sprintf() is a very comprehensive and powerful function"

    It is indeed!

    Just look it up in any 'C' textbook, and you'll that it takes several pages just to describe all the formatting options!
    If you think you could implement all that functionality in significantly less than 2.3K, there's nothing to stop you having a try...!

    Probably easier to just implement the bit you actually need, though... ;-)

    You could start by looking for open-source implementations of atoi, etc

Children