# your code goes hereimport bpy
from bpy import context
from math import sin, cos, radians

cubeobject = bpy.ops.mesh.primitive_cube_add

cursor = context.scene.cursor_location

radialdist = 5.0

xsize = 1.0
ysize = 1.0
zsize = 1.0
theta = 0.0
twopi_over_8 = 6.28 / 8.0

while theta < 6.28:
    x = cursor.x + radialdist * cos(theta)
    y = cursor.y + radialdist * sin(theta)
    z = cursor.z
    cubeobject(location = (x,y,z))
    
    theta+= twopi_over_8
    
theta = 0.0
radialdist = 1.0
    