 public class cylinder extends circle
 {
   protected double height;

 public cylinder( double h,circle d) throws zero_or_negative_sizeException
 { super(d);
   height=h;
 }
 
 public cylinder( double h, double r, double a, double b) throws zero_or_negative_sizeException
 { super(r,a,b);
   height=h;
 }
 
 public void enterheight (double h ) throws zero_or_negative_sizeException
 { if(h>0) height=h;
   else 
     throw new zero_or_negative_sizeException();
 } 

 public double readheight(){return height;}

 public double area()
 {return 2*super.area()+2*Math.PI*radius*height;} 

 public double volume(){return super.area()*height;}

 public String toString()
 {return super.toString()+";height = "+height;}

 public String name(){return "cylinder";}
}