Sprintf - Texas Instruments TI-89 Developer's Manual

Graphing calculator
Hide thumbs Also See for TI-89:
Table of Contents

Advertisement

986

sprintf

Declaration:
int sprintf (char * buf , const char * fmt_str , . . . )
Category(ies):
Strings, Utilities
Description:
The sprintf function formats and prints a series of characters to buf . Each
argument (if any) is converted and stored according to the corresponding
format specification in fmt_str . A null-character ('\0') is appended at the end
of the characters written.
The following standard conversions are supported.
%d %i
%u
%o
%b
%x %X — Integer argument is converted to hex notation (lower/upper
%p
Note:
%f
%e %E — Double argument is converted to decimal notation of the form
%g %G — Double argument is converted according to the %f or the %e
%c
%s
%%
TI-89 / TI-92 Plus Developer Guide
Appendix A: System Routines — Strings
— Integer argument is converted to signed decimal notation.
— Integer argument is converted to unsigned decimal notation.
— Integer argument is converted to octal notation.
— Integer argument is converted to binary notation.
case).
— Void * argument is converted to 0xhhhhhhhh form (same as
%#.8x).
The above conversions may be preceded by an 'l' to signify a long integer
argument.
— Double argument is converted to decimal notation of the form
[-]ddd.ddd (where ddd represents zero or more digits).
[-]d.ddde[+-]ddd.
format depending on the value converted.
— Integer argument is converted into an unsigned char.
— Char * argument is a pointer to string; string characters are
written up to null character or specified precision count.
— Literal '%'.
(continued)
Not for Distribution
Beta Version January 26, 2001

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Ti-92 plusTi-92 plus

Table of Contents