Portman wrote:
When I compile the program I get: Warning: W8012
c:\Borland\BCC55\Practice\Practice5_8.cpp 15: Comparing signed and
unsigned values in function main()
Warning: W8012 c:\Borland\BCC55\Practice\Practice5_8.cpp 25: Comparing
signed and unsigned values in function main()
Lines 15 and 25 are the for (int i . . . lines. I copied this letter by
letter from the book and keep getting this error - any ideas?
Change the 'for' loops to this
for (unsigned int i = 0; i < response.length();i++) {
and the warning should go away. All it's doing is warning you that the
two values being compared are not the same type. ints can hold negative
values and the length of a string could never be negative.
Sheila
http://www.shefen.com/
____ The WDVL Discussion List from WDVL.COM ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] or
use the web interface http://e-newsletters.internet.com/discussionlists.html/
Send Your Posts To: [email protected]
To change subscription settings, add a password or view the web interface:
http://intm-dl.sparklist.com/read/?forum=wdvltalk
________________ http://www.wdvl.com _______________________
You are currently subscribed to wdvltalk as: [email protected]
To unsubscribe send a blank email to [EMAIL PROTECTED]
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016
Please include the email address which you have been contacted with.