Can someone help me | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Can someone help me

I was doing the loan calculator and i have done this and it's correct but they say that it's not the same what they want but it is import java.util.Scanner; public class Program { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); int amount = scanner.nextInt(); System.out.println(amount ); int procenty = amount / 10; int Po1Miesiacu = amount - procenty; System.out.println(Po1Miesiacu); int procenty2 = Po1Miesiacu / 10; int Po2Miesiacu = Po1Miesiacu - procenty2; System.out.println(Po2Miesiacu); int procenty3 = Po2Miesiacu / 10; int Po3Miesiacu = Po2Miesiacu - procenty3; System.out.println(Po3Miesiacu); } }

16th Dec 2021, 10:27 PM
Zenitsu Agatsuma
1 Answer
+ 1
Did you read that: ".... outputs the remaining amount after 3 months." That means only the value after 3 months, NOT after each month.
16th Dec 2021, 11:00 PM
Coding Cat
Coding Cat - avatar