You are not logged in. Please login at to post your questions!


Need help in Java program

Ok, first off I'm quite new to programming so my program isn't great. This program is supposed to make the user answer a quiz and every time they answer correctly they get to pick a tile on a 3 by 3 tic tac toe board. If they answer incorrectly the computer randomly choses an unoccupied space on the board until either the user or the computer wins. The complete program is not finished yet but I'm having an issue with trivia questions repeating (I wrote some code that was supposed to flag a question after it is used so it doesn't get picked again for the sake of variety). It was just working fine until I got further into the program and now I noticed that I'm getting repeat questions despite the fact I wrote something to prevent it. I don't know where I messed up please help.

here is the code

here is the code when it was still working

Also the program I am using is ready to program with Java. thanks, I just dont get why it suddenly stopped working

Edit: I realized it's gonna be a pain to find what I'm talking about so it's this block which is found in the method quiz. So yea this is what was supposed to prevent the questions from being picked multiple times, which suddenly stopped working after I got further in the program. Here is the block of code I'm talking about:

asked 30 May '18, 10:26

cryptarch's gravatar image

accept rate: 0%

edited 30 May '18, 10:35

toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported
  • mathemetical formulas in Latex between $ symbol

Question tags:


question asked: 30 May '18, 10:26

question was seen: 85 times

last updated: 30 May '18, 10:35