LIZAK98%SNYBUFVA.BITNET@cornellc.cit.cornell.edu (A SHOW OF HANDS) (04/03/89)
Thanks to all who mailed me or posted to the amiga-relay possible
fixes to my problem. I realized that it was probably something very
simple and an easy fix, which it was. I am self teaching myself C, so
it's kinda hard to ask a book a question and get an answer easily... this
solution seemed to work the best for my needs:
#include <stdio.h>
main()
{
char a[80];
char *b;
int i;
b="Thanks All!";
strcpy(a,b);
for(i=0;a[i];i++)
putchar(a[i]);
}
I cannot believe the speed that sucker ran at! I was so used to BASIC
puttering along and dumping the string ever so slowly, this was a shocker!
The main purpose of running through a string in this manner is so I can
pull out characters of special meaning. That way I can imbed a series
of quotes, or whatever to print to the screen. For loops are hogs in BASIC..
Thanks Again,
Rob.