Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Simple question

  1. #1
    Junior Member
    Join Date
    Aug 2011
    Posts
    13
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default Simple question

    This is probably a pretty dumb question but here goes. How do I make a users decimal value display as a percentage later in my program. Say if user was asked for interest rate and they put .05. Later I want to say interest rate = 5%.


  2. #2
    Grand Poobah
    Join Date
    Mar 2011
    Posts
    1,545
    My Mood
    Grumpy
    Thanks
    0
    Thanked 167 Times in 158 Posts

    Default Re: Simple question

    Multiply by 100, convert to a String and add a % sign at the end.
    Improving the world one idiot at a time!

Similar Threads

  1. Help with a simple question
    By allea in forum What's Wrong With My Code?
    Replies: 3
    Last Post: May 28th, 2011, 07:46 AM
  2. Simple GUI/Animation question...
    By teslatrain in forum AWT / Java Swing
    Replies: 3
    Last Post: April 29th, 2011, 04:10 PM
  3. Just a simple question
    By newbie in forum Java Theory & Questions
    Replies: 10
    Last Post: December 6th, 2010, 08:19 PM
  4. simple question...
    By chronoz13 in forum Java Theory & Questions
    Replies: 2
    Last Post: February 2nd, 2010, 07:29 AM
  5. not so simple, simple swing question box
    By wolfgar in forum AWT / Java Swing
    Replies: 2
    Last Post: November 20th, 2009, 03:47 AM