forLoopEx2b.scad 327 B

12345678910
  1. // Note: The middle parameter in the range designation
  2. // ('0.2' in this case) is the 'increment-by' value
  3. // Warning: Depending on the 'increment-by' value, the
  4. // real end value will be smaller than the given one.
  5. for ( i = [0 : 0.2 : 5] )
  6. {
  7. rotate( i * 360 / 6, [1, 0, 0])
  8. translate([0, 10, 0])
  9. sphere(r = 1);
  10. }