0

Ok So Im writing a app which would pick the 'cheapest' plan for a consumer. While writing this I came across something puzzling to me. Why is it starting after the default constructor, the first CellPlan has three arguments passed too it and then the next one two and then one, why can the number be flipped around and be 1,2,3 or: 2,3,1 arguments (after the default constructor)?

//default constructor
        public CellPlan()
        { 
        }

        public CellPlan(string name, int zip, int minutes)
        {
            customerName = name;
            zipCode = zip;
            numberOfMinutes = minutes;
        } // end of CellPlan constructor

        public CellPlan(string name, int zip)
        {
            customerName = name;
            zipCode = zip;
        } // end of CellPlan constructor

        public CellPlan(int minutes)
        {
            numberOfMinutes = minutes;
        }

Thanks Again for all the help as always

2
Contributors
2
Replies
3
Views
5 Years
Discussion Span
Last Post by techlawsam
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.