Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the code to create a basic 2D sketch line in SolidWorks.
Solidworks
CreateLine([1], 0, 10, 0)
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing a non-zero start coordinate causes the line to start away from origin.
✗ Incorrect
The line starts at x=0 on the sketch plane, so the first coordinate must be 0.
2fill in blank
mediumComplete the code to set the length of the sketch line to 20 units.
Solidworks
SetLineLength(line1, [1]) Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using a length less than required results in a shorter line.
✗ Incorrect
The length of the line is set to 20 units as required.
3fill in blank
hardFix the error in the code to fully constrain the sketch line horizontally.
Solidworks
AddConstraint(line1, [1]) Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'Vertical' constraint locks the line vertically, which is incorrect.
✗ Incorrect
To constrain the line horizontally, the 'Horizontal' constraint must be applied.
4fill in blank
hardFill both blanks to define a rectangle sketch with width 30 and height 20.
Solidworks
CreateRectangle(width=[1], height=[2])
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Swapping width and height values causes incorrect rectangle dimensions.
✗ Incorrect
The rectangle's width is 30 units and height is 20 units as specified.
5fill in blank
hardFill all three blanks to fully define a circle sketch with center at (10, 15) and radius 5.
Solidworks
CreateCircle(centerX=[1], centerY=[2], radius=[3])
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up center coordinates or radius leads to wrong circle placement or size.
✗ Incorrect
The circle is centered at (10, 15) with a radius of 5 units.