Hai, can anyone help me?
missing return statement error keep appear when i tried to run this code

class CoffeeBags{
    //Data member
    private static final double PRICE_PER_LB = 5.99;
    private static final double TAX_RATE = 0.0725;
    private int numberOfBags;
    private double totalPrice;
    private double totalPriceWithTax;
    private int bagWeight;

    public CoffeeBags (double totalPrice, double totalPriceWithTax){
        //double totalPrice=0.0;

    //get method
    public double getTotalPrice(){

        return totalPrice;

    public double getTotalPriceWithTax(){
        return totalPriceWithTax;

    //set method
    public double settotalPrice(){
        totalPrice = bagWeight * numberOfBags * PRICE_PER_LB;

    public double settotalPriceWithTax(){
        totalPriceWithTax = totalPrice + totalPrice * TAX_RATE;

Methods settotalPrice() and settotalPriceWithTax() are both type double, but neither one has a return statement.

Your set methods (settotalPrice() and settotalPriceWithTax()) should be of the type void

oh. Ok guys. I got it. TYVM!