Results 1 to 2 of 2
  1. #1
    saifchenko is offline Member
    Join Date
    Mar 2011
    Rep Power

    Default Problems with my Assignment

    Users task is to guess 4 digits generated by my program. Those digits should be unique. My program should give a hint to users based on their guess.
    No. of Green Right digit at the right place
    No. of Red Right digit but at the wrong place

    For example :
    Number generated is 4589
    User guess is 4810
    Hint: 1 Green 1 Red

    Actually..I really doesnt understand the question..can someone explain it to me?:D

  2. #2
    sunde887's Avatar
    sunde887 is offline Moderator
    Join Date
    Jan 2011
    Richmond, Virginia
    Blog Entries
    Rep Power


    Have you started anything yet? The goal is for the user to continually guess numbers until they have guessed every number. After each guess you need to compare there choice to the data they are guessing.

    If they make a guess that is the right number in the right spot increment green. If they guess a number that is correct, but in the wrong spot, increment red, then display them.

    Try storing the targets in a 4 item array. Give it a shot and see how you do, you can also start small with 2 targets digits at a time.

Similar Threads

  1. Can somebody help me in this assignment?
    By lulzim in forum New To Java
    Replies: 25
    Last Post: 03-02-2011, 12:02 AM
  2. Need Help With Assignment
    By zeo in forum New To Java
    Replies: 10
    Last Post: 02-25-2011, 01:09 AM
  3. Recursion assignment problems
    By tfitz666 in forum New To Java
    Replies: 11
    Last Post: 01-24-2010, 10:18 PM
  4. GUI First Assignment-DUE 8/1/08
    By ljk8950 in forum AWT / Swing
    Replies: 2
    Last Post: 08-01-2008, 04:23 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts