I need help with an app game purchase

I recently added 20$ to my account with 2 10$ Itunes cards. I play the app called clash of clans, in the game you can buy things with itunes, I tried to make a purchase for 19.99 when there is just about 21 $ in my itunes and it's telling me I have insufficient funds. This is odd becusee a couple days ago I did the same thing with the itunes card but now I'm getting this error. I checked my itunes again and I have the money, please help!

What country are you in ? If you are in the US then does your state's sales tax take it over what you have on your account ?

Similar Messages

  • Need help with ending a game

    i'm making a game at the moment.......
    i need help with a way to check all the hashmaps of enimies in a class called room......i need to check if they all == 0...when they all equal zero the game ends......
    i know i can check the size of a hash map with size().....but i want to check if all the hashmaps within all the rooms == 0.

    First of all stop cross posting. These values in the HashMap, they are a "Collection" of values, so what is wrong with reply two and putting all these collections of values into a super collection? A collection of collections? You can have a HashMap of HashMaps. One HashMap that holds all your maps and then you can use a for loop to check if they are empty. A map is probably a bad choice for this operation as you don't need a key and an array will be much faster.
    HashMap [] allMaps = {new HashMap(),new HashMap()};

  • Newbie needs help with Flex app

    Hi there. I am very new to Flex and also fairly new to
    programming although I do have a little experience.
    I am trying to create an app which stores code snippets or
    common text I tend to use every day in my documents and emails.
    So basically I need help on a design level. I can refer to
    the developer's manual for exact instructions for commands, but I
    need to know what to code first.
    The app will consist of:
    -a tree directory structure where I can create groups.
    -There will be a basic text editor where I input all my data,
    basic text formatting options (font, bullets etc) would be a bonus.
    -A search function
    -Finally it will ideally allow multiple client apps write to
    a central database file over a network
    Can anyone suggest how I should approach such a project?
    Or are there any tutorials / source files which demonstrate
    each bullet point?
    thanks.

    Hey jono,
    I'm new too. But I think I might know the right components.
    If you google any of these + flex 3 you should get some
    decent documentation
    tree - advanced dataGrid component
    basic text editor - rich text editor component
    search function - well, you're gonna need to read up on
    arrays, and arraycollection. Once you get that stuff working, you
    can write up a function to search for a string in an array.
    network functionality - HTTPService, you can dump the
    datagrid into a database, and have it load the database when you
    open up the application.
    Give these things a shot, tutorials / sources will come with
    the google searches.

  • I really need help with my decision in purchasing an iPhone 4! =(

    I will just go to my main concern.
    I lost the phone of my aunt which is an iPhone 4. It was stolen from my bag. Out of common sense, I have to find a replacement because I know the my aunt invested money on it. However, brand new iPhone 4 here on our country are still pretty expensive for my budget. It is also hard to find becuase mostly stores no longer carry it becuase there is now iPhone 5. So, i have no choice, but to purchase a second-hand iPhone 4. So far, the second-hand iPhone 4 that I saw are from Singapore and Japan.
    Now, my question. How can I be sure that the iPhone 4 that I purchase will work in the United States when my aunt will go back to the US. She works and live in the United States. I want to make sure that she can use the phone when she goes back to the United States.
    Please please please I need help.
    I am already stressed finding money to buy a replacement. 

    Verizon's offers full theft and loss protection. I am an attorney and tend to read fine print :)
    The $8 a month is nominal compared to the benefit and peace of mind. I have had it on all my phones and typically you have to ask for it.
    Over the past two years I have used it twice. My phone at the time was an HTC Evo, about a $500 phone. To replace outside the 2yr contact you must pay full price. That is $1000 for 2 phones.
    The insurance cost me a couple hundred plus the deductibles. That's under $500 to replace two phones, or a savings of about $500 or 50%.
    Even if you replace 1 phone in two years, your saving a few hundred- more if its an iPhone which retails starting at $700.
    It all depends on where and how you use your device. If you never replaced one before the you may be better off without. I also don't put cases or screen protectors on my phones. I wouldn't dare put one on my beautiful iPhone 5.
    Just a thought, if you don't have insurance, you should be ready to drop $750 at any given time for a new iPhone. Otherwise you end up with a temporary flip.

  • HOW CAN I SPEAK WITH A LIVE HUMAN? I need help with what I just purchased.

    I just bought something which is suppose to allow me to convert a PDF file on line to a word document and I do not know enough about computers to understand what you require me to do. Please help.
    Thank you,
    Paul

    Hi Paul,
    I would be happy to help you here. Please see Getting Started with ExportPDF | Adobe Community to information on converting your PDF files to Word format.
    And, if you'd rather, you can Contact Customer Care. Just click the blue Still Need Help button at the bottom of the page to find phone and chat options.
    Best,
    Sara

  • Need help with installing app.

    I need help installing .jar file on my Droid phone.

    Oh, man, the last time I heard of a .JAR file was on a Motorola Razr!
    That ain't goin' on a Droid....
    Unless you have some more context to share about this.....
    Geri O

  • HT204088 Need help with in app purchase

    I spent $60 on an app called clash of clans and did not get the gems

    If you haven't received the item then try the 'report a problem' page to contact iTunes Support (these are user-to-user forums) : http://reportaproblem.apple.com
    If the 'report a problem' link doesn't work then you can try contacting iTunes Support via this page : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Purchases, Billing & Redemption

  • I need help with downloading apps?

    I got an iPad 2 today and I entered all my details in and also my bank details in, but then it's saying to me to enter 'security code' in? And I don't know what it is. I have realised that a lot of people are having this problem and it obviously needs to be sorted? Please help me?????

    Thanks for your responses but when I go on app store and then on featured, I press 'free app' and then it says 'install app' and then I click on 'use existing apple id' - so then I enter my username and password, then all my bank details ans everything else, there all correct but then it comes up with... 'your payment method was declined, please enter another payment method' - all I want is FREE apps, no paid ones? Is there anyway I could get around this? - I have noticed a lot of people are having this problem HELPPPPP lol x

  • Need help with Java app for user input 5 numbers, remove dups, etc.

    I'm new to Java (only a few weeks under my belt) and struggling with an application. The project is to write an app that inputs 5 numbers between 10 and 100, not allowing duplicates, and displaying each correct number entered, using the smallest possible array to solve the problem. Output example:
    Please enter a number: 45
    Number stored.
    45
    Please enter a number: 54
    Number stored.
    45 54
    Please enter a number: 33
    Number stored.
    45 54 33
    etc.
    I've been working on this project for days, re-read the book chapter multiple times (unfortunately, the book doesn't have this type of problem as an example to steer you in the relatively general direction) and am proud that I've gotten this far. My problems are 1) I can only get one item number to input rather than a running list of the 5 values, 2) I can't figure out how to check for duplicate numbers. Any help is appreciated.
    My code is as follows:
    import java.util.Scanner; // program uses class Scanner
    public class Array
         public static void main( String args[] )
          // create Scanner to obtain input from command window
              Scanner input = new Scanner( System.in);
          // declare variables
             int array[] = new int[ 5 ]; // declare array named array
             int inputNumbers = 0; // numbers entered
          while( inputNumbers < array.length )
              // prompt for user to input a number
                System.out.print( "Please enter a number: " );
                      int numberInput = input.nextInt();
              // validate the input
                 if (numberInput >=10 && numberInput <=100)
                       System.out.println("Number stored.");
                     else
                       System.out.println("Invalid number.  Please enter a number within range.");
              // checks to see if this number already exists
                    boolean number = false;
              // display array values
              for ( int counter = 0; counter < array.length; counter++ )
                 array[ counter ] = numberInput;
              // display array values
                 System.out.printf( "%d\n", array[ inputNumbers ] );
                   // increment number of entered numbers
                inputNumbers++;
    } // end close Array

    Yikes, there is a much better way to go about this that is probably within what you have already learned, but since you are a student and this is how you started, let's just concentrate on fixing what you got.
    First, as already noted by another poster, your formatting is really bad. Formatting is really important because it makes the code much more readable for you and anyone who comes along to help you or use your code. And I second that posters comment that brackets should always be used, especially for beginner programmers. Unfortunately beginner programmers often get stuck thinking that less lines of code equals better program, this is not true; even though better programmers often use far less lines of code.
                             // validate the input
       if (numberInput >=10 && numberInput <=100)
              System.out.println("Number stored.");
      else
                   System.out.println("Invalid number.  Please enter a number within range."); Note the above as you have it.
                         // validate the input
                         if (numberInput >=10 && numberInput <=100)
                              System.out.println("Number stored.");
                         else
                              System.out.println("Invalid number.  Please enter a number within range."); Note how much more readable just correct indentation makes.
                         // validate the input
                         if (numberInput >=10 && numberInput <=100) {
                              System.out.println("Number stored.");
                         else {
                              System.out.println("Invalid number.  Please enter a number within range.");
                         } Note how it should be coded for a beginner coder.
    Now that it is readable, exam your code and think about what you are doing here. Do you really want to print "Number Stored" before you checked to ensure it is not a dupe? That could lead to some really confused and frustrated users, and since the main user of your program will be your teacher, that could be unhealthy for your GPA.
    Since I am not here to do your homework for you, I will just give you some advice, you only need one if statement to do this correctly, you must drop the else and fix the if. I tell you this, because as a former educator i know the first thing running through beginners minds in this situation is to just make the if statement empty, but this is a big no no and even if you do trick it into working your teacher will not be fooled nor impressed and again your GPA will suffer.
    As for the rest, you do need a for loop inside your while loop, but not where or how you have it. Inside the while loop the for loop should be used for checking for dupes, not for overwriting every entry in the array as you currently have it set up to do. And certainly not for printing every element of the array each time a new element is added as your comments lead me to suspect you were trying to do, that would get real annoying really fast again resulting in abuse of your GPA. Printing the array should be in its own for loop after the while loop, or even better in its own method.
    As for how to check for dupes, well, you obviously at least somewhat understand loops and if statements, thus you have all the tools needed, so where is the problem?
    JSG

  • I need help with iAD/App development!

    So I released an app, and it went on sale yesterday on the App Store (free app: if you want it, the developer name is Abdulrahman Ahmad, and the game name is Space Defense), but I'm having some problems. When I was testing the app (on an iPhone, and on the xCode Simulator), the ads were working, and I was getting "You're iAD is configured correctly (or whatever the test ads say)" but now that the app has finally released, no ads are appearing (but iTunes Connect says that the ads are live?). Also, I released 2 different versions of the app (2 downloads, 1 was optimized for 5 inch screen, one for 3.5 in (just figured out how to make it one app, that'll be coming out in the update), and when I was looking at my iTunes Connect iAD portal, only 1 app was showing up to have adds (the 3.5 inch one doesn't have ads for some reason?):
    SO! Summery if I confused you:
    iAD was working in the testing phase of the app, but not showing up now(even though iTunes Connect says ads are live)?
    And 1 of my apps is not showing up in my iTunes Connect iAD terminal...
    Any and all help appreciated!
    Thanks in advance!

    RE: Nevermind, i guess it takes a day or so for ads to finally start showing, and i guess i forgot to check off iad compatibility with the second app!

  • TS1424 Need help with netflix app over wifi on iphone 4

    I have iPhone 4 which is 3G.  I used the Netflix app on this phone. I recently got a new phone. I stopped the phone service and cell data plan to my iPhone 4. The netflix app still worked fine over wifi connection.  Suddenly, I am unable to connect to netflix.  I was going to try to remove and reinstall but I now cannot connect to iTunes store.  I found something that said I need to set up the phone to sync with wifi on iTunes, which I did.  synced again.  App still won't work and still cannot connect to iTunes store from phone.  My other iPhone 5 works fine but I need the netflix on the older iPhone 4 because of connection to tv.
    any ideas?????  I've tried signing out of netflix and back in on computer...  can't get in to Netflix app to even sign out then in.

    You can change the email address of an Apple ID without creating a new account. Apparently you didn't do this. You will need to Authorize the computer using the AppleID and password that the content was purchased with.
    Try connecting the phone, but DO NOT SYNC. Go to the iTunes File menu and choose Transfer Purchases. This should put the apps and music purchased with the old account into the iTunes library. Launch of of the songs and you should be prompted for the password to authorize that account.

  • RE: Need Help with Designing a game of  "GO"

    I have got the GUI sorted thanks to some source code supplied by Noah.W. I wish to add animation to the program below.
    Can someone please help me with the capture methods in the below code. I basically need it to capture all pieces that have been surrounded by opposing pieces. This may be one piece or a whole group captured.
    At the moment it only does it for one piece.
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    import java.util.*;
    public class GoGame extends JFrame
    public GoGame()
         getContentPane().setLayout(null);
         setBounds(10,10,510,520);
         getContentPane().add(new TheTable());
         setVisible(true);
    public class TheTable extends JPanel
         int[][]points  = new int[19][19];
         boolean black  = true;
    public TheTable()
         setBounds(20,20,453,453);
         addMouseListener(new MouseAdapter()
              public void mouseReleased(MouseEvent m)
                   Point p = clickOnIntersection(m.getPoint());
                   if (p != null && points[p.x/25][p.y/25] == 0)
                        int x = p.x/25;
                        int y = p.y/25;
                        if (black)
                             points[x][y] = 1;
                             black = false;
                             capture(x,y,2,1);
                             capture(x,y,1,2);
                        else
                             points[x][y] = 2;
                             black = true;
                             capture(x,y,1,2);
                             capture(x,y,2,1);
                        repaint();
    private Point clickOnIntersection(Point p)
         Rectangle rh = new Rectangle(0,0,getWidth(),5);
         Rectangle rv = new Rectangle(0,0,5,getHeight());
         for (int h=0; h < 19; h++)
              rh.setLocation(0,h*25-2);
              if (rh.contains(p))
                   for (int v=0; v < 19; v++)
                        rv.setLocation(v*25-2,0);
                        if (rv.contains(p)) return(new Point(v*25+1,h*25+1));
         return(null);
    private void capture(int x1, int y1, int col0, int col1)
         for (int x=Math.max(0,x1-2); x < Math.min(19,x1+2); x++)
              for (int y=Math.max(0,y1-2); y < Math.min(19,y1+2); y++)
                   if (points[x][y] == col0) capture(x,y,col1);
    private void capture(int x, int y, int col)
         if (x > 0  && points[x-1][y] != col) return;
         if (x < 18 && points[x+1][y] != col) return;
         if (y > 0  && points[x][y-1] != col) return;
           if (y < 18 && points[x][y+1] != col) return;
         points[x][y] = 0;
    public void paintComponent(Graphics g)
         super.paintComponent(g);
         Graphics2D g2 = (Graphics2D)g;
         g2.setPaint(new GradientPaint(getWidth(),getHeight(),Color.yellow,0,0,Color.red,true));
         g2.fillRect(0,0,getWidth(),getHeight());
         g2.setColor(Color.black);
         for (int n=0; n < 19; n++)
              g2.fillRect(0,n*25,getWidth(),3);
              g2.fillRect(n*25,0,3,getHeight());
         g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,RenderingHints.VALUE_ANTIALIAS_ON);          
         g2.setColor(Color.green) ;
         for (int n=0; n < 3; n++)
              g2.fillOval(25*3-1,n*150+74,5,5);
              g2.fillOval(25*9-1,n*150+74,5,5);
              g2.fillOval(25*15-1,n*150+74,5,5);
         for (int x=0; x < 19; x++)
              for (int y=0; y < 19; y++)
                   if (points[x][y] != 0)
                        if (points[x][y] == 1) g.setColor(Color.black);     
                        if (points[x][y] == 2) g.setColor(Color.white);     
                        g2.fillOval(x*25-9,y*25-9,20,20);
    public static void main(String[] args)
         GoGame game = new GoGame();
         game.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    }

    I am also willing to reward �20 via Paypal for the complete solution to the game of "GO", excluding the animation element. Half can be emailed first, then the rest after payment.

  • Need help with " Number guessing game " please?

    This is what teacher requires us to do for this assignment:
    Write a program that plays a simple number guessing game. In this game the user will think of a number and the program will do the guessing. After each guess from the program, the user will either indicate that the guess is correct (by typing �c�), or that the next guess should be higher (by typing �h�), or that it should be lower (by typing �l�). Here is a sample output for a game. In this particular game the user thinks of the number 30:
    $java GuessingGameProgram
    Guess a number between 0 and 100
    Is it 50? (h/l/c): l
    Is it 25? (h/l/c): h
    Is it 37? (h/l/c): l
    Is it 31? (h/l/c): l
    Is it 28? (h/l/c): h
    Is it 29? (h/l/c): h
    Is it 30? (h/l/c): c
    Thank you for playing.
    $
    This program is implementing a binary search algorithm, dividing the range of possible values in half with each guess. You can implement any algorithm that you want, but, all things being equal, binary search is the best algorithm.
    Write the program so that the functionality is split between two classes: GuessingGameProgram, and NumberGuesser.
    GuessingGameProgram will only be used for its main function. It should instantiate a NumberGuesser, and it will be responsible for the loop that notifies the user of the next guess, reads the �h�, �l�, or �c� from the user, and sends an appropriate message to the number guesser accordingly.
    The guesses themselves should all be generated by the NumberGuesser class. Here is a diagram of the members and methods for the class. Notice that the members are unspecified. Feel free to give your NumberGuesser class any members (which we have also been calling fields, or instance variables) that you find useful. Make them all private.
    NumberGuesser
    NumberGuesser(int upperLimit, int lowerLimit)
    int guess()
    void higher()
    void lower()
    The constructor should take two integer arguments, a lower and upper bound for the guesses. In your program the constructor will be called with bounds of 0 and 100.
    The guess method should return the same value if it is called more than once without intervening calls to the lower or higher methods. The class should only change its guess when it receives a message indicating that its next guess should be higher or lower.
    Enjoy. Focus your attention on the NumberGuesser class. It is more interesting than the GuessingGameProgram class because it is a general-purpose class, potentially useful to anybody who is writing a number guessing game. Imagine, for instance, that a few weeks from now you are asked to write a number guessing game with a graphical Java Applet front end. If you NumberGuesser class is well written, you may be able to reuse it without any modifications.
    I'm new to JAVA and I'm set with my 2nd homework where I'm so confused. I know how to do something of this source in C language, but I'm a bit confused with Java. This is the code me and my classmate worked on, I know it's not 100% of what teacher asked, but is there any way possibly you guys could help me? I wrote this program if the game is played less then 10 times, thought I would then re-create a program without it, but now I'm confused, and my class book has nothing about this :( and I'm so confused and lost, can you please help? And out teacher told us that it's due the end of this week :( wish I knew what to do. Thank you so so much.
    Here's the code:
    import java.text.*;
    import java.io.*;
    class GuessingGame
    public static void main( String[] args ) throws IOException
    BufferedReader stdin = new BufferedReader(new InputStreamReader( System.in ) );
    int guess = 0, limit = 9, x = 0, n, a = 0 ;
    double val = 0 ;
    String inputData;
    for ( x = 1; x <= 10; x++)      //number of games played
    System.out.println("round " + x + ":");
    System.out.println(" ");
    System.out.println("I am thinking of a number from 1 to 10. ");
    System.out.println("You must guess what it is in three tries. ");
    System.out.println("Enter a guess: ");
    inputData = stdin.readLine();
    guess = Integer.parseInt( inputData );
    val = Math.random() * 10 % limit + 1;     //max limit is set to 9
    NumberFormat nf = NumberFormat.getNumberInstance();
    nf.setMaximumFractionDigits(0);               //format number of decimal places
    String s = nf.format(val);
    val = Integer.parseInt( s );
         for ( n = 1; n <= 3; n++ )      //number of guess's made
                   if ( guess == val)
                        System.out.println("RIGHT!!");                    //if guess is right
                        a = a + 1;
                        System.out.println("You have won " + a + " out of " + x + " rounds");
    System.out.println(" ");
    n = 3;
    continue;
              if (n == 3 && guess != val)                         //3 guesses and guess is wromg
                        System.out.println("wrong");
    System.out.println("The correct number was " + val);
                        System.out.println("You have won " + a + " out of " + x + " rounds");
    System.out.println(" ");
    continue;
                   //how close guess is to value
                   if ( guess == val - 1 || val + 1 == guess) //Within 1
                   System.out.println("hot");
         else if ( guess == val - 2 || val + 2 == guess) // Within 2
                   System.out.println("warm");
              else
                   System.out.println("cold");                         // Greater than 3
         inputData = stdin.readLine();
         guess = Integer.parseInt( inputData );
    //ratings
    if ( a <= 7)
         System.out.println("Your rating is: imbecile.");
    else if ( a <= 8)
         System.out.println("Your rating is: getting better but, dumb.");
    else if (a <= 9)
         System.out.println("Your rating is: high school grad.");
    else if ( a == 10)
         System.out.println("Your rating is: College Grad.!!!");

    Try this.
    By saying that, I expect you ,and your classmate(s), to study this example and then write your own. Hand it in as-is and you'll be rumbled as a homework-cheat in about 20ms ;)
    When you have an attempt where you can explain, without refering to notes, every single line, you've cracked it.
    Also (hint) comment your version well so your tutor is left with the impression you know what you're doing.
    In addition (huge hint) do not leave the static inner class 'NumberGuesser' where it is. Read your course notes and find out where distinct classes should go.
    BTW - Ever wonder if course tutors scan this forum for students looking for help and/or cheating?
    It's a double edged sword for you newbies. If you ask a sensible, well researched question, get helpful answers and apply them to your coursework, IMHO you should get credit for doing that.
    On the other hand, if you simply post your assignment and sit there hoping some sucker like me will do it for you, you should be taken aside and given a good kicking - or whatever modern educational establishments consider appropriate abmonishment ;)
    I'd say this posting is, currently, slap bang between the two extreemes, so impress us. Post your solution in the form you intend to hand it in, and have us comment on it.
    Good luck!
    import java.io.InputStreamReader;
    import java.io.BufferedReader;
    public class GuessingGame
         public static void main(String[] args)
              throws Exception
              BufferedReader reader= new BufferedReader(
                   new InputStreamReader(System.in));
              NumberGuesser guesser= new NumberGuesser(0, 100);
              System.out.println(
                   "\nThink of a number between 0 and 100, oh wise one...");
              int guess= 0;
              while (true) {
                   guess= guesser.guess();
                   System.out.print("\nIs it " +guesser.guess() +"? (h/l/c) ");
                   String line= reader.readLine();
                   if (line == null) {
                        System.out.println(
                             "\n\nLeaving? So soon? But we didn't finish the game!");
                        break;
                   if (line.length() < 1) {
                        System.out.println("\nPress a key, you muppet!");
                        continue;
                   switch (line.toLowerCase().charAt(0)) {
                        case 'h':  
                             guesser.higher();
                             break;
                        case 'l':     
                             guesser.lower();
                             break;
                        case 'c':
                             System.out.println("\nThank you for playing.");
                             System.exit(0);
                        default:
                             System.out.println(
                                  "\nHow hard can it be? Just press 'h' 'l' or 'c', ok?");
                             continue;
                   if (guess == guesser.guess()) {
                        System.out.println(
                             "\nIf you're going to cheat, I'm not playing!");
                        break;
         private static class NumberGuesser
              private int mLower;
              private int mUpper;
              private int mGuess;
              NumberGuesser(int lowerLimit, int upperLimit)
                   mLower= lowerLimit;
                   mUpper= upperLimit;
                   makeGuess();
              private void makeGuess() {
                   mGuess= mLower + ((mUpper - mLower) / 2);
              int guess() {
                   return mGuess;
              void higher()
                   mLower= mGuess;
                   makeGuess();
              void lower()
                   mUpper= mGuess;
                   makeGuess();
    }                  

  • Need help with a guessing game

    Hi. hopefully, this is a really easy issue to resolve. I had to write a program that administers a guessing game, where the computer chooses a random number, and the user has to guess the number. If the user doesn't get it within 5 guesses, they lose and start all over with a new number. I have this all in a while loop (as per my instructions). My issue is that whenever the user enters 0, the program should quit with the users final score and so on. My program will not quit unless the 0 is entered on the last (fifth) guess. please help, it would be very appreciated. Here is my code:
    import java.util.Scanner;
      public class guessgame {
        public static void main(String[] args) {
          Scanner scanner = new Scanner (System.in);
            int randnum;        //random number generated by computer
            int userguess = 1;      //number the user guesses
            int userscore = 0;      //number of correct guesses by user
            int compscore = 0;      //number of times not guessed
            int guessnum = 0;       //number of guesses for one number
            int gamenum = 0;        //number of games played
        System.out.println ("I will choose a number between 1 and 10");
        System.out.println ("Try to find the number using as few guesses as possible");
        System.out.println ("After each guess i will tell you if you are high or low");
        System.out.println ("Guess a number (or 0 to quit)");
        while (userguess != 0) {
          randnum = 1 + (int)(Math.random() * 10); //generates random number
          gamenum ++;
          userguess = userguess;
            for (guessnum = 1; guessnum < 6 && userguess != randnum; guessnum ++) {
                userguess = scanner.nextInt();
                userguess = userguess;
               if (guessnum >= 5) {
                  System.out.println ("You did not guess my number!");
                                  } //closes if statement
               if (userguess == randnum) {
                 userscore ++;
                 System.out.println ("You guessed it! It took you " + guessnum + " tries.");
                 System.out.println ("If you want to play again, enter a guess");
                 System.out.println ("If you do not want to play again, enter 0");
                                        } //closes if statement
               else if (userguess < randnum)
                 System.out.println ("Your guess is too low");
               else if (userguess > randnum)
                 System.out.println ("Your guess is too high");
                                                          }//closes for loop
                              } //closes while loop
    compscore = gamenum - userscore;
            System.out.println ("Thanks for playing! You played " + gamenum + " games");
            System.out.println ("Out of those " + gamenum + " games, you won " + userscore + " times");
            System.out.println ("That means that I won " + compscore + " times"); 
    } //closes main
    } //ends guessgame class

    The problem with your program is that the while loop doesn't get checked. The condition of the while loop will only get checked each iteration, and not during one iteration. The time you are in your for-loop is still one iteration so it won't check if userguess is 0. see it liek this
    While: is userguess 0, no, do 1 iteration
    while-iteration-forloop: check 5 guesses, userguess can be anything even 0 while loop won't stop.
    end of for loop
    end of while-iteration
    new while iteration, is userguess 0?
    and so on.
    HTH,
    Lima

  • Need help with Camera app

    Hello RIM support,
    I am a new owner of BB Playbook.  Everything seems to be working okay except camera app.  I can take a picture with it but nothing will show up in picture app.  According to the help video, the pictures taken by camera app should show up in picture app from the menu option.
    Please help.
    Thanks
    Kevin
    Solved!
    Go to Solution.

    Yes, your pictures taken with the Playbook camera certainly should show in the Pictures folder on the Playbook.
    Just for the heck of it, can you try turning your Playbook off and back on and check your Pictures app/folder again?
    1. If any post helps you please click the below the post(s) that helped you.
    2. Please resolve your thread by marking the post "Solution?" which solved it for you!
    3. Install free BlackBerry Protect today for backups of contacts and data.
    4. Guide to Unlocking your BlackBerry & Unlock Codes
    Join our BBM Channels (Beta)
    BlackBerry Support Forums Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

Maybe you are looking for

  • Problem with Auo Increment field in Database table

    HI... I have a table with Auto increment field. I am using Sql Server 2000. I have a Table Component on front end which is binded with that (auto increment) table. When I call commitChanges() I receive following exception : Exception Details:  java.l

  • Problem setting up OD Replica

    I am attempting to set up an Open Directory replica server in Lion server 10.7.1 I have the master set up and working (as far as I can tell) fine. When I go to the second machine and attempt to set it up as an open directory replica, it looks like it

  • Xselsius in the HEBREW language

    Hello, In Xselsius, when I write the title or any text with fonts from the HEBREW language I cant see the fonts in the published report. I'm getting blanks instead. Please Advice, David

  • Renaming Master files

    In the release documentation it mentions that you can rename the Master Files(not referring to naming versions, but actually renaming the master file) in version 1.5. Does anybody know how to do this? I can't seem to find any mention of it. thanks

  • Upgrading Photoshop and getting onto new laptop

    I have Photoshop CS4 Student Edition on my current laptop and it came with 2 copies (you could put it on 2 computers), but I've had to put both my copies on the laptop because I upgrade my OS at one point from Vista to Windows 7 and the first copy go