Im really struggling with what seems to be an easy task, however Im not able to make this work.
I need to get the parent inside of a collection that's already in a collection,
with the code im using
print(collection)
if collection.name == doorname:
door = collection.children[0]
print(door) //OUTPUT: <bpy_struct, Collection("Door") at 0x7ff8f180b678>
for objects in door:
print(objects) //Error
I want all the objects in the Door collection to be printed. Is there a way to do this, what am I missing?
Thanks in advance!

for o in door.objectsorfor o in door.all_objectsto get all objects in door collection and its children. – batFINGER Feb 24 '21 at 10:48