write a program to enter principal
Attachments:
Answers
Answered by
0
Answer:
import java.util.Scanner;
public class Main
{
public static void main (String args[])
{
Scanner sc = new Scanner(System.in);
float p, r, t, si;
System.out.println("Enter the Principal:");
p = sc.nextFloat();
System.out.println("Enter the Rate:");
r = sc.nextFloat();
System.out.println("Enter the Time:");
t = sc.nextFloat();
si = (p*r*t)/100;
System.out.println("Simple Interest is: " +si);
}}
Explanation:
Similar questions