• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem looping back to beginning

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I originally had this posted in the intermediate forum, but my second problem doesn't seem as difficult. I thought it was better suited here, so I deleted the original and moved it here.

My problem is that I want to be able to loop my program back to the beginning after it is done. With the "Would you like to play again(Y/N)" statement. I tried a Do While statement and followed the general setup of it, but I've had no luck with it. I'm not sure where my problem is because I get no error when I compile, and it runs everything up until where it asks whether I want to play again or not. Suggestions to what is wrong would be well appreciated.


[ October 21, 2004: Message edited by: MP Olsen ]
 
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Should this be:
 
MP Olsen
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, I feel dumb after that. My fault not reading the code more carefully. I believe I had it right originally then I moved the code and it was changed. In the process, I never really realized it was different, and I guess I didn't notice it.

Thanks
[ October 21, 2004: Message edited by: MP Olsen ]
 
Nathaniel Stoddard
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It's all right. A well-battered forehead is the mark of a great developer.
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
and we've all been thankful of a second set of eyes at the right time. Nice catch
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic