please read full question and don't write follow or any other message please else I have to report the answer because from half an hour all are doing this
Write a program in bluej to buy pencils, copies, erasers at respectively prices(pencils=20,copies=100,erasers=50) and calculate the total amount of these items Please tell fast
AND YA THIS QUESTION IS NOT OF MATHS IT'S OF COMPUTER
Answers
Answered by
1
Answer:
import java.util.*;
class price
{
public static void main ()
{
Scanner sc=newScanner(System.in);
int P,C,E,Np,Nc,Ne,A;
System.out.println("Enter no.of pencils you want to buy:");
Np= sc.nextInt();
System.out.println("Enter no.of copies you want to buy:");
Nc= sc.nextInt();
System.out.println("Enter no. of erasers you want to buy:");
Ne= sc.nextInt();
P=20*Np;
C=100*Nc;
E=50*Ne;
A=P+C+E;
System.out.println("Total amount to be paid="+A);
}
}
Answered by
1
Answer:
my insta id dreamboy_al
Explanation:
you can talk to me there
Similar questions