• Post Reply Bookmark Topic Watch Topic
  • New Topic

What I need to have possibility to press enter for executing program again  RSS feed

 
Gennadiy Rabkin
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi )
I wrote simple console program from book exercises which generate playing card (rank and suit). I want to have some fun and add to program possibility to be executed again, when pressed Enter from keyboard for example, without closing applet viewer. Is it possible to do? What I should to know to do that, something about inputLine() and scanner, or anything else?
 
Shamsudeen Akanbi
Ranch Hand
Posts: 85
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Gennadiy, i think you should post your code. I can't imagine how it looks like so thats why nobody's gonna help.
 
Gennadiy Rabkin
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Shamsudeen Akanbi wrote:Gennadiy, i think you should post your code. I can't imagine how it looks like so thats why nobody's gonna help.


Nothing special except of acm library usage:

 
Gennadiy Rabkin
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to implement using Scaner?
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!