Accessing Inherited Functions

  • + 1 comment

    void update_val(int new_val) { while(val!=new_val) { // here get count that is equal to number of times // you divide new_val by 2 and call so many times // A::func(val) A::func(val); // here get count that is equal to number of times // you divide new_val by 3 and call so many times // B::func(val) B::func(val); // here get count that is equal to number of times // you divide new_val by 5 and call so many times // C::func(val) C::func(val); }
    }