let item = Item()
if item is Item {
print("object is of Item subclass type")
} else {
print("object is not of Item subclass type")
}
let myArray: [Int] = [1, 2, 5]
if myArray is Array<Int> {
print("Indeed it is array")
}
// Generic이므로 타입을 명시해준다
let objectType = type(of: 4)
Int.Type
print("Object type: \(objectType)")
타입 그자체를 저장함