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: Java Methods and Percentages

  1. #1
    Junior Member
    Join Date
    Jul 2014
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Java Methods and Percentages

    Hi there,

    I have a 'small' question:

    I am trying to create a method that will deduct the same percentage for a number of times, example:

    a + b = c

    c - 3% = d

    d - 3% = e

    e - 3% = f......

    and so on and so forth, for a number specified earlier in the program, until I get to my final result.

    Could you kindly give me some hints please?

    Regards


  2. #2
    Crazy Cat Lady KevinWorkman's Avatar
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    5,424
    My Mood
    Hungover
    Thanks
    144
    Thanked 636 Times in 540 Posts

    Default Re: Java Methods and Percentages

    And what about this are you stuck on? Where is your MCVE?

    Recommended reading: The for Statement (The Java™ Tutorials > Learning the Java Language > Language Basics)
    Useful links: How to Ask Questions the Smart Way | Use Code Tags | Java Tutorials
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

Similar Threads

  1. Java Methods - Beginner
    By dinosaur1993 in forum What's Wrong With My Code?
    Replies: 3
    Last Post: March 17th, 2014, 04:41 PM
  2. Java help with Methods (Begginer)
    By maddiexc in forum What's Wrong With My Code?
    Replies: 4
    Last Post: June 15th, 2013, 10:53 PM
  3. Need help with calling methods in Java.
    By searock in forum Java Theory & Questions
    Replies: 2
    Last Post: February 2nd, 2013, 02:22 PM
  4. Why and where abstract methods & classes and static methods are used?
    By ajaysharma in forum Object Oriented Programming
    Replies: 7
    Last Post: July 14th, 2012, 01:16 AM
  5. Can I do this with methods in Java?
    By mjballa in forum Java Theory & Questions
    Replies: 2
    Last Post: February 4th, 2012, 08:55 PM

Tags for this Thread