/*
* A printf object.
* mmcg, Jun 27, 1992
*/
reset() {
return 0;
}
/*
* fmt is a c-style format string.
* args is an array of arguments.
*/
printf(fmt, args) {
string o;
string s;
int x;
o = "";
x = 0;
do {
y = index(fmt, '%', x);
if (y < 0) {
o = o + fmt[x..];
}
else {
o = o + fmt[x..y-1];