PPT Slide
Introduction to Programming, Lecture 3
Last lecture, we looked at a model for a box:
class Box {
int iLength; int iWidth; int iHeight;
public void setLength (int iNewLength) {
util.ASSERT (iNewLength > 0,
“iNewLength <= 0”);
iLength = iNewLength;
} // of setLength
public int getLength ( ) {
return (iLength);
} // of getLength
Previous slide
Next slide
Back to first slide
View graphic version