Am I doing these problems right?

Discussion in 'Programming General' started by kmjt, Jan 26, 2011.

Am I doing these problems right?
  1. Unread #1 - Jan 26, 2011 at 12:25 PM
  2. kmjt
    Joined:
    Aug 21, 2009
    Posts:
    14,450
    Referrals:
    8
    Sythe Gold:
    449

    kmjt -.- The nocturnal life chose me -.-
    Banned

    Am I doing these problems right?

    Done thanks.
     
  3. Unread #2 - Jan 26, 2011 at 12:44 PM
  4. Pottworth
    Joined:
    Nov 27, 2005
    Posts:
    83
    Referrals:
    0
    Sythe Gold:
    0

    Pottworth Member

    Am I doing these problems right?

    Just tested that for you, works totally fine. I'd code the bottom part as one System.out.print, but thats just me :D
     
  5. Unread #3 - Jan 26, 2011 at 1:13 PM
  6. kmjt
    Joined:
    Aug 21, 2009
    Posts:
    14,450
    Referrals:
    8
    Sythe Gold:
    449

    kmjt -.- The nocturnal life chose me -.-
    Banned

    Am I doing these problems right?

    Thanks for testing. And yaa i'm going to change bottom.. it's only like that because I didn't have room to do it on one line when I was making the program (I was writing it on a piece of paper with a pencil aha.) Putting up my second program in a few minutes.
     
  7. Unread #4 - Jan 27, 2011 at 7:36 AM
  8. Fate1
    Joined:
    Apr 21, 2005
    Posts:
    773
    Referrals:
    2
    Sythe Gold:
    5

    Fate1 Apprentice
    Banned

    Am I doing these problems right?

    For your top program. You are going to want to use the nextDouble() method instead of nextInt(). If you are asking for a double and the program only looks for an int it is going to throw an error when you run it. Also not really sure why you did that but the bottom brackets are the wrong ones.
     
< Detect an image, then clicking on that image? | Keylogger? wat? >

Users viewing this thread
1 guest


 
 
Adblock breaks this site