Your group visit a shop to get your
assignment typed and printed. WAP to
calculate bill of a job work based on following
rates.
• Rate of typing is Rs. 3/- per page
• Printing of fist copy if Rs. 5/- per page and
later every copy Rs. 3/- per page.
User should enter the number of pages in
assignment and no. of print out copies your
group want.
Answers
Answered by
3
Answer:
sorry I did not get you
Explanation:
sorry i can't answer
Answered by
0
Answer:
import java.util.Scanner;
class BillingCounter
{
public static void main()
{
Scanner sc=new Scanner(System.in);
System.out.println("Enter the no. of pages in assignment and the no. of member in the group");
int page=sc.nextInt();
int memb=sc.nextInt();
int totalpg=memb*page;
int calc=page*3;
if(page==1)
calc+=page*5;
else if(page>1)
calc+=(1*5)+((page-1)*3)
System.out.println("total bill = "+calc);
}
}
......this is the coding in blueJ using Scanner class
Similar questions