class + objects

records + arrays


records and object (class)

Loading…

define a record format: define a class
name the class (record format)
define the fields (variables) for the record format
public class season {
int seasonDays;
String seasonName;
}

// declare a single record (object)
season winter = new season()

array of records, array of objects

Loading…

declare an array of records: array of objects
season[] seasonList = new season[4];
Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.