getting objects from scene that contain a certain string

Does any1 know how or if it’s possible to get a list of objects from the scene who contain a certain string into an array.

as an example something like:

scene = logic.getCurrentScene()
for target in scene.objects:
if target == ‘cube_orange*’:
nList.append(target)

I would like to get a list of objects who contain the string ‘cube_orange’, so in the end
nlist == [cube_orange, cube_orange.001, cube_orange.002, cube_orange.etc]

I would also like to know if its possible to get them in the abc order…

ok, nevermind. i just found that i need to write


if 'cube_orange' in target.name:
    nList.append(target)