![deaishaajennings123](/avatars/5939.jpg)
deaishaajennings123
08.10.2021 •
Mathematics
4) 52.959
The 5 in the tens place is
the value of the 5 in the hundredths place.معمولی مطمطمطم
Solved
Show answers
More tips
- S Sport Running: How to Do It Right?...
- F Food and Cooking How to Cook Spaghetti Right – Secrets and Tips...
- P Philosophy Personal attitude towards Confession: how to prepare and undergo the procedure correctly?...
- H Health and Medicine Flu: How to Recognize It by the First Symptoms?...
- F Food and Cooking How to Sober Up Quickly? Important Facts and Tips...
- H Health and Medicine How to Properly Take a Blood Sugar Test?...
- H Health and Medicine Simple and Effective: How to Get Rid of Cracked Heels...
- O Other How to Choose the Best Answer to Your Question on The Grand Question ?...
- L Leisure and Entertainment History of International Women s Day: When Did the Celebration of March 8th Begin?...
- S Style and Beauty Intimate Haircut: The Reasons, Popularity, and Risks...
Answers on questions: Mathematics
- M Mathematics I need help with this please :)...
- M Mathematics Can someone explain how to evaluate logarithmic equations ?...
- M Mathematics Find an explicit formula for the geometric sequence below. , -7,-21/4,-63/16,-189/64,-567/256...
- M Mathematics Any one? can i please get help with these two problems...
- M Mathematics I will give anyone brainlist if they answer this question Divide and reduce to lowest terms 2 1/4 divided by 4/5...
- M Mathematics What is the perimeter of DEF, rounded to the nearest tenth of a unit ?...
- M Mathematics Hello help me with this one please...
- M Mathematics Please help I’ll give you extra points HELPS...
- M Mathematics Histograms or polygons graphs can be used to display the same types of data. True or False?...
- M Mathematics Can someone explain two ways i can solve a logarithmic equation?...
Ответ:
import java.util.*;
import java.text.*;
class CreditCardBill
{
public static void main(String[] args)
{
Scanner sc = new Scanner(System.in);
NumberFormat defaultFormat = NumberFormat.getCurrencyInstance(Locale.US);
System.out.println("CS Card International Statement");
System.out.println("");
System.out.print("Previous Balance: $");
double prevBalance = sc.nextDouble();
System.out.print("Additional Charges: $");
double addCharges = sc.nextDouble();
double interest;
if(prevBalance == 0)
interest = 0;
else
interest = (prevBalance + addCharges) * 0.02;
System.out.println("Interest: "+defaultFormat.format(interest));
double newBalance = prevBalance + addCharges + interest;
System.out.println("New Balance: "+defaultFormat.format(newBalance));
double minPayment;
if(newBalance < 50)
minPayment = newBalance;
else if(newBalance <= 300)
minPayment = 50.00;
else
minPayment = newBalance * 0.2;
System.out.println("Minimum Payment: "+defaultFormat.format(minPayment));
}
}