# square()

### Example

![](https://768248463-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fqbs7pgU3AVBY06Rl9M31%2Fuploads%2FhUrs6DIaJBC0VLWTquqU%2Fsquare%20plain.png?alt=media\&token=82d8e73e-7ba5-4d3a-be73-fdedc7e7062a)

```python
square(100, 100, 200)
```

### Syntax

```python
square(x, y, length)
```

<table><thead><tr><th width="167">Input</th><th>Description</th></tr></thead><tbody><tr><td>x</td><td>x co-ordinate of the bottom left corner</td></tr><tr><td>y</td><td>y co-ordinate of the bottom left corner</td></tr><tr><td>length</td><td>length of the square (length in x direction and y direction)</td></tr></tbody></table>

<figure><img src="https://768248463-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fqbs7pgU3AVBY06Rl9M31%2Fuploads%2FgAUR2BT3JmFFbYd0OG9m%2Fsquare%20plain.png?alt=media&#x26;token=3e11b8bc-5a71-4c1c-858c-733e96bb19bd" alt=""><figcaption></figcaption></figure>

### Description

**square()** draws a square on the canvas, using the inputs to determine the position and dimension of the shape. The corners can be given a curvature in order to draw a 'rounded square', but the length and height of the square must always be equal to one another. Also, the length and height need to be parallel to the x-axis and y-axis respectively - this can only be changed separately with a rotation.

{% hint style="info" %}
Find these documents helpful? Let the people who made them help your child learn to code at [**Strivemath**](https://www.strivemath.com/)<mark style="color:blue;">**!**</mark>

We'd love to hear your Feedback/Comments [here](https://docs.google.com/forms/d/e/1FAIpQLSeqorBAGTya-YBRI-VFjJxtgQtCz3ucGDI96K96sNyuaGuvdw/viewform?usp=sf_link).
{% endhint %}
