ASP Fractal

HTML Output

ASP Code

<%

Dim depth,color,size
depth=5
size=1
color="blue"

Call DrawFractal (depth)

Sub DrawFractal (depth)

%>
<table border= "0" cellpadding= "0" cellspacing= "0"><tr><td>
<% Call Iterate (depth) %>
</td></tr><tr><td>
<% Call Iterate (depth) %>
</td><td>
<% Call Iterate (depth) %>
</td></tr></table>
<%

End Sub

Sub Iterate (depth)
    If depth > 0 Then
        Call DrawFractal (depth-1)
    Else
        Response.Write "<table cellpadding=""0"" cellspacing=""0"" " & _
            " border=""0"" height="""& size &""" width="""& size &""">" & _
            "<tr><td bgcolor="""& color &"""></td></tr></table>"
    End If
End Sub

%>

You might also like...

Comments

Tawani Anyangwe

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.” - Antoine de Saint Exupéry