Meshing a cube with a cubic whole

Hello everybody, i am completely new to Salome so i appologize for my poor knowledge in advance. i am trying to create a geometry which is a simple cube. then i want to create a whole in it which itself is cube also. i managed to do it using Cut boolean operator and now i have my desired geometry like this:

the domain size is 5cm in each direction and the whole section is a cube with 1cm in each direction.
now i want to mesh this domain with cubic cells. but i dont know how to mesh this geometry. i have tried some algorithms but couldn’t do it successfuly.
i appreciate if anybody could solve my naive question :slight_smile:

Surely someone could provide some smarter approach and guidelines on how to proceed, but on could here make use of body fitting algorithm, which seems to mesh this case.

Script: SF1600.py (2.5 KB)