# Can someone help by making my code into a SVG file?

**URL:** <https://discourse.processing.org/t/can-someone-help-by-making-my-code-into-a-svg-file/35874>\
**Category:** Coding Questions\
**Tags:** homework\
**Created:** [March 21, 2022, 9:21am UTC](https://discourse.processing.org/t/can-someone-help-by-making-my-code-into-a-svg-file/35874 "2022-03-21T09:21:07Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![C.J](https://avatars.discourse-cdn.com/v4/letter/c/48db29/32.png) [@C.J](https://discourse.processing.org/u/C.J)\
**Post date:** [March 21, 2022, 9:21am UTC](https://discourse.processing.org/t/can-someone-help-by-making-my-code-into-a-svg-file/35874/1 "2022-03-21T09:21:07Z")

</div>

Hey!

I’m a student CS at a Highschool in the Netherlands and I need some help.

I’ve been making a code but I can’t seem to make it into a SVG file. Could someone help me with that?  
Here’s the code:

//code made by C.J

int ellipseSize = 30;  
int gridSize = 30;

size(700, 700);  
background(255, 255, 255);

int c = 0;  
while ( c \< 10) {  
c += 1;  
println(c);  
int j = 0;  
while (j \< 10) {  
print(j + " ");  
j += 1;  
int posX = c \* 60;  
int posY = j \* 60;

```
//float = is een beetje random(20);
float dist = 20;

//float is een beetje random(20);
float col = 255;

//float is een beetje random(60);
float elSz = random(60);

ellipse(posX, posY, elSz, elSz);
ellipse(posX + 20, posY + dist * 2, elSz, elSz);
noFill();

```

}  
println();  
}

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [March 21, 2022, 10:18am UTC](https://discourse.processing.org/t/can-someone-help-by-making-my-code-into-a-svg-file/35874/2 "2022-03-21T10:18:20Z")

</div>

Hello @C.J,

I followed the first _SVG Export (No Screen Display)_ example here and put your code in the _draw()_ loop:

> **[SVG Export / Libraries](https://processing.org/reference/libraries/svg/index.html)**
>
> Create SVG files.

SVG Output:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/2X/9/983f9ab175261a1d2c113894fdfa185cc67450dd.png)

`:)`
