First consider the volume of the given figure 
Volume =length x width x height 
V=L x W x H 
B=2 1/2=2.5 cm , L=2 cm , H=1 cm
V= 2.5 x 2 x 1 =5 cm3 
Considering the volume of the given cube 
L=H=W 
For a cube the sides are the same 
V = L x W x H L = 1/2 = 0.5 
V= (L)3 
V=(0.5)3 
V=0.125 cm3 
Hence number of cubes 
= volume of cube / volume of fig 
= 0.125/5
=0.05 cubes