create.Car <- function(x, wheels=4, doors=2) list(wheels=wheels, doors=doors)
my.car <- create(Car, doors=4)
your.car <- create('Car', wheels=6)
her.class <- 'Car'
her.car <- create(her.class, wheels=3)
isa(Car, my.car)Run the code above in your browser using DataLab