Write a java program that uses inheritance to extend box. Use the extend keyword to include weight.
// use the super keyword to access the variables
//of the parent class, remember that only weight(m)
//was declared in this class but the other three
//were declared in the parent class so to access them
//you must use the super keyword otherwise the
//compiler will generate an error.
reiyn17 0 Newbie Poster
glowkazaf 0 Newbie Poster
reiyn17 0 Newbie Poster
masijade 1,351 Industrious Poster Team Colleague Featured Poster
javaAddict 900 Nearly a Senior Poster Team Colleague Featured Poster
Ezzaral 2,714 Posting Sage Team Colleague Featured Poster
lovely12 0 Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.