From abcc540713896f594759e6199bded19d401cdec9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20Schw=C3=B6rer?= Date: Fri, 11 Jul 2014 19:29:19 +0200 Subject: [PATCH] Added Blogposts --- .idea/workspace.xml | 625 +++++----- DB_Changes.txt | 2 + www/data/blog/Befunge_1/Euler_Problem-01.b93 | 5 + www/data/blog/Befunge_1/Euler_Problem-02.b93 | 5 + www/data/blog/Befunge_1/Euler_Problem-03.b93 | 4 + www/data/blog/Befunge_1/Euler_Problem-04.b93 | 6 + www/data/blog/Befunge_1/Euler_Problem-05.b93 | 6 + www/data/blog/Befunge_1/Euler_Problem-06.b93 | 16 + www/data/blog/Befunge_1/Euler_Problem-07.b93 | 156 +++ www/data/blog/Befunge_1/Euler_Problem-08.b93 | 29 + www/data/blog/Befunge_1/Euler_Problem-09.b93 | 7 + www/data/blog/Befunge_1/Euler_Problem-10.b93 | 1007 +++++++++++++++++ www/data/blog/Befunge_1/Euler_Problem-11.b93 | 31 + .../02_TextFunge/01_Language.markdown | 478 ++++++++ .../programs/desc/BefunGen/index.markdown | 2 +- www/javascript/prism.js | 5 + www/protected/config/main.php | 8 + .../controllers/BlogPostController.php | 191 ++++ www/protected/models/BlogPost.php | 99 ++ .../views/blogPost/_ajaxMarkdownPreview.php | 3 + www/protected/views/blogPost/_form.php | 52 + www/protected/views/blogPost/_search.php | 26 + www/protected/views/blogPost/_view.php | 25 + www/protected/views/blogPost/admin.php | 57 + www/protected/views/blogPost/create.php | 20 + www/protected/views/blogPost/index.php | 23 + www/protected/views/blogPost/update.php | 26 + www/protected/views/blogPost/view.php | 24 + www/protected/views/layouts/main.php | 4 +- www/protected/views/log/_form.php | 2 +- www/protected/views/programs/admin.php | 5 - www/protected/views/programs/index.php | 3 + 32 files changed, 2606 insertions(+), 346 deletions(-) create mode 100644 www/data/blog/Befunge_1/Euler_Problem-01.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-02.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-03.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-04.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-05.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-06.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-07.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-08.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-09.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-10.b93 create mode 100644 www/data/blog/Befunge_1/Euler_Problem-11.b93 create mode 100644 www/protected/controllers/BlogPostController.php create mode 100644 www/protected/models/BlogPost.php create mode 100644 www/protected/views/blogPost/_ajaxMarkdownPreview.php create mode 100644 www/protected/views/blogPost/_form.php create mode 100644 www/protected/views/blogPost/_search.php create mode 100644 www/protected/views/blogPost/_view.php create mode 100644 www/protected/views/blogPost/admin.php create mode 100644 www/protected/views/blogPost/create.php create mode 100644 www/protected/views/blogPost/index.php create mode 100644 www/protected/views/blogPost/update.php create mode 100644 www/protected/views/blogPost/view.php diff --git a/.idea/workspace.xml b/.idea/workspace.xml index 78046a7..26ffd26 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -2,13 +2,13 @@ - - - - + + + + @@ -63,55 +63,64 @@ - - + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -130,18 +139,7 @@ @@ -363,32 +372,6 @@ + - @@ -791,24 +714,24 @@ - - - - - - - + - + + + + + + + - + @@ -836,91 +759,11 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -936,11 +779,6 @@ - - - - - @@ -961,11 +799,6 @@ - - - - - @@ -998,49 +831,19 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - + @@ -1052,77 +855,225 @@ - - - - - - - - - - + - - - + - - - - - - - - - - + - - - + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/DB_Changes.txt b/DB_Changes.txt index 126ff74..4447238 100644 --- a/DB_Changes.txt +++ b/DB_Changes.txt @@ -22,6 +22,8 @@ updates -> Adjust 'Link' updates -> 'Name' Type is VARCHAR(64) updates -> Removed col 'Log' +ms4_log -> Added + updateslog -> new table db->createCommand('SELECT * FROM {{updates}}')->queryAll(); diff --git a/www/data/blog/Befunge_1/Euler_Problem-01.b93 b/www/data/blog/Befunge_1/Euler_Problem-01.b93 new file mode 100644 index 0000000..4b0c8a4 --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-01.b93 @@ -0,0 +1,5 @@ +vvv: < < +1> 1+:::3/3*-!#^_>::5/5*-!#^_v +1$v ># v# ># v#< +1 >:5558***-!|v$<>+\:1-!|v$< +>^ <>$$^\ <>.@ \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-02.b93 b/www/data/blog/Befunge_1/Euler_Problem-02.b93 new file mode 100644 index 0000000..3a9439b --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-02.b93 @@ -0,0 +1,5 @@ +v>v>ppp 0>>$ 10g20g:10p+:v +202 >00p0^|-*2/2::< vp02< +0::0^+ g00^@$.g00<>*` #v_^ +>^ ^ < \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-03.b93 b/www/data/blog/Befunge_1/Euler_Problem-03.b93 new file mode 100644 index 0000000..a0d062c --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-03.b93 @@ -0,0 +1,4 @@ +89197939490919v >00g10g1-:10p%#v_10g:30p1-40pv +v+*29191929891< ^ < <_v#! %g04g03< +>*+*+*+*+*+*+*v >"{.i "+**10p#^ #p #0 #0 <>40g:1-40p2-| + >#^ +# *# +# *# +# *# +# *# +# <@.g03< \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-04.b93 b/www/data/blog/Befunge_1/Euler_Problem-04.b93 new file mode 100644 index 0000000..4c65324 --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-04.b93 @@ -0,0 +1,6 @@ +1:010:pp5558***04p>10g1+::10p04g-00g \#v_1+:00p\$1:10p\:04g- #v_$$03g.@ + ^ v $< >1# 0# 1# p# *# :# v# < + v_v#-g1-g20g10g 1g2002g1+:02p 01 g - | > ^ + > ^ >:03g\`#v_03pv + ^ $< 0< \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-05.b93 b/www/data/blog/Befunge_1/Euler_Problem-05.b93 new file mode 100644 index 0000000..430767c --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-05.b93 @@ -0,0 +1,6 @@ +45*00p110p120p >10g20g*10p00g20g1+:20p`#v_10g.@ + ^_v#`g00p03+1:g03 10g30g% |1 <^ p01/g03g01< + >10g30g/40p150p > 20g50g1+:50p` #v_^ + ^ < |!%g05g04 < + ^< \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-06.b93 b/www/data/blog/Befunge_1/Euler_Problem-06.b93 new file mode 100644 index 0000000..12bb68f --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-06.b93 @@ -0,0 +1,16 @@ +"d"10p000p>10g:00g+00p1-:#v_$010p>"c"10g::1+:*\:5:+%\5:+/6+p`#v_ v +>$.@ ^ p01< ^ p01+1g01 < 0 + > v +|!:\<|p01-1:g01<$$_v#!:g+6/+:5\%+:5:g01 :< p01"c"+<_v#!p01:-1g01` > #v_v +> v v-g+6/+:5\%+:5:g01< >00g ^ +##########> ^ +########## >010g:5:+%\5:+/6+pv +########## +########## ^ < < +########## +########## +########## +########## +########## +########## \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-07.b93 b/www/data/blog/Befunge_1/Euler_Problem-07.b93 new file mode 100644 index 0000000..d979b1f --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-07.b93 @@ -0,0 +1,156 @@ +v // Project Euler - Problem 7 +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## +######################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################## + v < +>"d"55+*:10p3"2"*:20p*00p230p" ":01p11p10g5:+*1+50pv > 030p 040p>30g1+:30p:10g%\10g/1+g"X"- | +v < _^#`g03g00 <|p+1/g01\%g01:g03"0"-p04:+1g04g05< +> "X" 30g:10g%\10g/1+p30g >30g+ : 00g\` #v_$>30g1+:30p:10g%\10g/1+g" "- |>30g.@ + ^p+1/g01\%g01:\" ":< ^ < \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-08.b93 b/www/data/blog/Befunge_1/Euler_Problem-08.b93 new file mode 100644 index 0000000..50143ac --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-08.b93 @@ -0,0 +1,29 @@ +"v"00p54*:10p552**:20p*30p85+40p050p060p070p080p > +>150g60p>60g:20g%\20g/9+g"0"-*60g1+:60p50g-40g-#v_:80g`#v_$>50g1+:50p30g-#v_ 970p >70g0g.70g8-40g-#v_"=",80g.@ + ^ < ^ < + >80p060p>60g50g+:2 0g%\20g /9+g"0"-60g9+0p6 0g1+:60p40g-#v_^ +^ < ^p07+1g07 < + ^ < + + + +73167176531330624919225119674426574742355349194934 +96983520312774506326239578318016984801869478851843 +85861560789112949495459501737958331952853208805511 +12540698747158523863050715693290963295227443043557 +66896648950445244523161731856403098711121722383113 +62229893423380308135336276614282806444486645238749 +30358907296290491560440772390713810515859307960866 +70172427121883998797908792274921901699720888093776 +65727333001053367881220235421809751254540594752243 +52584907711670556013604839586446706324415722155397 +53697817977846174064955149290862569321978468622482 +83972241375657056057490261407972968652414535100474 +82166370484403199890008895243450658541227588666881 +16427171479924442928230863465674813919123162824586 +17866458359124566529476545682848912883142607690042 +24219022671055626321111109370544217506941658960408 +07198403850962455444362981230987879927244284909188 +84580156166097919133875499200524063689912560717606 +05886116467109405077541002256983155200055935729725 +71636269561882670428252483600823257530420752963450 \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-09.b93 b/www/data/blog/Befunge_1/Euler_Problem-09.b93 new file mode 100644 index 0000000..d83baee --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-09.b93 @@ -0,0 +1,7 @@ +"d"5:+*00p210p> 120p>v >20g1+:20p10g-#v_10g1+:10p00g-#v_ @ + ^ < + ^ < +v < +>20g:*10g:*+:30p0>::*30g-#v_:30p20g10g++ 00g-#v_20g:." ",10g:." ",30g:."=",**.@ + |-g00 :+1< + >$$ ^ $< \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-10.b93 b/www/data/blog/Befunge_1/Euler_Problem-10.b93 new file mode 100644 index 0000000..81b61e9 --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-10.b93 @@ -0,0 +1,1007 @@ +v // Project Euler - Problem 7 +################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################ +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# #### ######################## # +# #### ######################## # +# #### ######################## # +# #### ######################## # +# ################################################################ # +# ################################################################ # +# ################################################################ # +# ################################################################ # +# ######################################################################################## # +# ######################################################################################## # +# ######################################################################################## # +# ######################################################################################## # +# ################################################################################################################# # +# ################################################################################################################# # +# ################################################################################################################# # +# ################################################################################################################# # +# ################################################################################################################################# # +# ################################################################################################################################# # +# ################################################################################################################################# # +# ################################################################################################################################# # +# ################################################################################################################################################# # +# ################################################################################################################################################# # +# ################################################################################################################################################# # +# ################################################################################################################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ######################################################### ################################################# # +# ################################################ ############################################# # +# ################################################ ############################################# # +# ################################################ ############################################# # +# ################################################ ############################################# # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# #################################################### ######################################### # +# ################################################ ############################################# # +# ################################################ ############################################# # +# ################################################ ############################################# # +# ################################################ ############################################# # +# ######################################## ############################################# # +# ######################################## ############################################# # +# ######################################## ############################################# # +# ######################################## ############################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# ############################################ ################################################# # +# #### ############################################ ############################################ # +# #### ############################################ ############################################ # +# #### ############################################ ############################################ # +# #### ############################################ ############################################ # +# ######################################################################### ################################################ # +# ######################################################################### ################################################ # +# ######################################################################### ################################################ # +# ######################################################################### ################################################ # +# ##################################################################################### ############################################ # +# ##################################################################################### ############################################ # +# ##################################################################################### ############################################ # +# ##################################################################################### ############################################ # +# ################################################################################################# ################################################ # +# ################################################################################################# ################################################ # +# ################################################################################################# ################################################ # +# ################################################################################################# ################################################ # +# ################################################################################################# ################################################ # +# ######################################################################################################### ############################################ # +# ######################################################################################################### ############################################ # +# ######################################################################################################### ############################################ # +# ######################################################################################################### ############################################ # +# ############################################################################################################# ######################################## # +# ############################################################################################################# ######################################## # +# ############################################################################################################# ######################################## # +# ############################################################################################################# ######################################## # +# ##################################################################################### #################### ######################################## # +# ##################################################################################### #################### ######################################## # +# ##################################################################################### #################### ######################################## # +# ##################################################################################### #################### ######################################## # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ######################################################################################### ################ #################################### # +# ############################################################################################# ################ #################################### # +# ############################################################################################# ################ #################################### # +# ############################################################################################# ################ #################################### # +# ############################################################################################# ################ #################################### # +# ################################################################################################# ################ ################################ # +# ################################################################################################# ################ ################################ # +# ################################################################################################# ################ ################################ # +# ################################################################################################# ################ ################################ # +# ############################################################################################# ############ ################################ # +# ############################################################################################# ############ ################################ # +# ############################################################################################# ############ ################################ # +# ############################################################################################# ############ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ################################ # +# ############################################################################################# ################ ############################ # +# ############################################################################################# ################ ############################ # +# ############################################################################################# ################ ############################ # +# ############################################################################################# ################ ############################ # +# ######################################################################################### ################ ######################## ############################ # +# ######################################################################################### ################ ######################## ############################ # +# ######################################################################################### ################ ######################## ############################ # +# ######################################################################################### ################ ######################## ############################ # +# ##################################################################################### ################ ################################################ ############################ # +# ##################################################################################### ################ ################################################ ############################ # +# ##################################################################################### ################ ################################################ ############################ # +# ##################################################################################### ################ ################################################ ############################ # +# ################################################################################# ################ ######## ######################################################################## ############################ # +# ################################################################################# ################ ######## ######################################################################## ############################ # +# ################################################################################# ################ ######## ######################################################################## ############################ # +# ################################################################################# ################ ######## ######################################################################## ############################ # +# ######################################################################### ################ ################ ######################################################################################## ############################ # +# ######################################################################### ################ ################ ######################################################################################## ############################ # +# ######################################################################### ################ ################ ######################################################################################## ############################ # +# ######################################################################### ################ ################ ######################################################################################## ############################ # +# ############################################################ ################################################ #################################################################################################### ############################ # +# ############################################################ ################################################ #################################################################################################### ############################ # +# ############################################################ ################################################ #################################################################################################### ############################ # +# ############################################################ ################################################ #################################################################################################### ############################ # +# ############################################################ #################################################### ######################################################################## ######################## ######################## # +# ############################################################ #################################################### ######################################################################## ######################## ######################## # +# ############################################################ #################################################### ######################################################################## ######################## ######################## # +# ############################################################ #################################################### ######################################################################## ######################## ######################## # +# #################################################################### #################################################### ############################################################################ ######################### ############################ # +# #################################################################### #################################################### ############################################################################ ######################### ############################ # +# #################################################################### #################################################### ############################################################################ ######################### ############################ # +# #################################################################### #################################################### ############################################################################ ######################### ############################ # +# ##################################################################################################################################################### ################################################################################ ######################### ######################## # +# ##################################################################################################################################################### ################################################################################ ######################### ######################## # +# ##################################################################################################################################################### ################################################################################ ######################### ######################## # +# ##################################################################################################################################################### ################################################################################ ######################### ######################## # +# ############################################################################################################################################# #################################################################################### ############################# ############################ # +# ############################################################################################################################################# #################################################################################### ############################# ############################ # +# ############################################################################################################################################# #################################################################################### ############################# ############################ # +# ############################################################################################################################################# #################################################################################### ############################# ############################ # +# ################################################################################################################################# ######################################################################################### ############################# ######################## # +# ################################################################################################################################# ######################################################################################### ############################# ######################## # +# ################################################################################################################################# ######################################################################################### ############################# ######################## # +# ################################################################################################################################# ######################################################################################### ############################# ######################## # +# ######################################################################################################################### ######################################################################################### ############################# ############################ # +# ######################################################################################################################### ######################################################################################### ############################# ############################ # +# ######################################################################################################################### ######################################################################################### ############################# ############################ # +# ######################################################################################################################### ######################################################################################### ############################# ############################ # +# #################### ############################################################################# ############################################################################################# ######################### ######################## # +# #################### ############################################################################# ############################################################################################# ######################### ######################## # +# #################### ############################################################################# ############################################################################################# ######################### ######################## # +# #################### ############################################################################# ############################################################################################# ######################### ######################## # +# ######################## #### ############################################# ############################################################################################# ######################### ######################## # +# ######################## #### ############################################# ############################################################################################# ######################### ######################## # +# ######################## #### ############################################# ############################################################################################# ######################### ######################## # +# ######################## #### ############################################# ############################################################################################# ######################### ######################## # +# ######################## ##################################### ######## ############################################################################################# ######################### ######################## # +# ######################## ##################################### ######## ############################################################################################# ######################### ######################## # +# ######################## ##################################### ######## ############################################################################################# ######################### ######################## # +# ######################## ##################################### ######## ############################################################################################# ######################### ######################## # +# #################### ################################# ############ ############################################################################################# ############################# ############################ # +# #################### ################################# ############ ############################################################################################# ############################# ############################ # +# #################### ################################# ############ ############################################################################################# ############################# ############################ # +# #################### ################################# ############ ############################################################################################# ############################# ############################ # +# ######################## ################################# ################ ################################################################################################# ##################### ######################## # +# ######################## ################################# ################ ################################################################################################# ##################### ######################## # +# ######################## ################################# ################ ################################################################################################# ##################### ######################## # +# ######################## ################################# ################ ################################################################################################# ##################### ######################## # +# #################### ##################################### #################### ############################################################################################# ##################### ############################ # +# #################### ##################################### #################### ############################################################################################# ##################### ############################ # +# #################### ##################################### #################### ############################################################################################# ##################### ############################ # +# #################### ##################################### #################### ############################################################################################# ##################### ############################ # +# ######################## ##################################################################################### ######################################################################################### ##################### ############################ # +# ######################## ##################################################################################### ######################################################################################### ##################### ############################ # +# ######################## ##################################################################################### ######################################################################################### ##################### ############################ # +# ######################## ##################################################################################### ######################################################################################### ##################### ############################ # +# ######################## ##################################################################################### ######################################################################################### ##################### ############################ # +# ############################ ##################################################################################### ############################################################################################# ################# ############################ # +# ############################ ##################################################################################### ############################################################################################# ################# ############################ # +# ############################ ##################################################################################### ############################################################################################# ################# ############################ # +# ############################ ##################################################################################### ############################################################################################# ################# ############################ # +# ############################ ################################################################################# ######################################################################################### ################# ############################ # +# ############################ ################################################################################# ######################################################################################### ################# ############################ # +# ############################ ################################################################################# ######################################################################################### ################# ############################ # +# ############################ ################################################################################# ######################################################################################### ################# ############################ # +# ############################ #### ################################################ ######################################################################### ############# ################################ # +# ############################ #### ################################################ ######################################################################### ############# ################################ # +# ############################ #### ################################################ ######################################################################### ############# ################################ # +# ############################ #### ################################################ ######################################################################### ############# ################################ # +# ############################################ ############################################# #### #### ################# ############################ # +# ############################################ ############################################# #### #### ################# ############################ # +# ############################################ ############################################# #### #### ################# ############################ # +# ############################################ ############################################# #### #### ################# ############################ # +# ################################################################ ##################################### ############# ############################ # +# ################################################################ ##################################### ############# ############################ # +# ################################################################ ##################################### ############# ############################ # +# ################################################################ ##################################### ############# ############################ # +# ######################################################################################## ############################################# ############ ################################ # +# ######################################################################################## ############################################# ############ ################################ # +# ######################################################################################## ############################################# ############ ################################ # +# ######################################################################################## ############################################# ############ ################################ # +# ######################################################################################################### ######################################################## #################### ############################ # +# ######################################################################################################### ######################################################## #################### ############################ # +# ######################################################################################################### ######################################################## #################### ############################ # +# ######################################################################################################### ######################################################## #################### ############################ # +# ##################################################################################################################################### #################################################################################################### ################################ # +# ##################################################################################################################################### #################################################################################################### ################################ # +# ##################################################################################################################################### #################################################################################################### ################################ # +# ##################################################################################################################################### #################################################################################################### ################################ # +# ################################################################################################################################################# #################################################################################### ############################ # +# ################################################################################################################################################# #################################################################################### ############################ # +# ################################################################################################################################################# #################################################################################### ############################ # +# ################################################################################################################################################# #################################################################################### ############################ # +# ############################ ######################################################################################################################### ############################################################################ #################################### # +# ############################ ######################################################################################################################### ############################################################################ #################################### # +# ############################ ######################################################################################################################### ############################################################################ #################################### # +# ############################ ######################################################################################################################### ############################################################################ #################################### # +# ############################ #### ############################################################################################################# ######################################################## ################################ # +# ############################ #### ############################################################################################################# ######################################################## ################################ # +# ############################ #### ############################################################################################################# ######################################################## ################################ # +# ############################ #### ############################################################################################################# ######################################################## ################################ # +# ############################ ############################################################################################################# #### #### ################################ # +# ############################ ############################################################################################################# #### #### ################################ # +# ############################ ############################################################################################################# #### #### ################################ # +# ############################ ############################################################################################################# #### #### ################################ # +# ############################ ######################################################################################################## ################################ # +# ############################ ######################################################################################################## ################################ # +# ############################ ######################################################################################################## ################################ # +# ############################ ######################################################################################################## ################################ # +# ######################## #### ################################################################################################# ################################ # +# ######################## #### ################################################################################################# ################################ # +# ######################## #### ################################################################################################# ################################ # +# ######################## #### ################################################################################################# ################################ # +# ############################ ######################################################################################### ################################ # +# ############################ ######################################################################################### ################################ # +# ############################ ######################################################################################### ################################ # +# ############################ ######################################################################################### ################################ # +# ############################ #### ################################################################################# ################################ # +# ############################ #### ################################################################################# ################################ # +# ############################ #### ################################################################################# ################################ # +# ############################ #### ################################################################################# ################################ # +# ############################ ############################################################################# #################################### # +# ############################ ############################################################################# #################################### # +# ############################ ############################################################################# #################################### # +# ############################ ############################################################################# #################################### # +# ################################# #################################################### #################################### # +# ################################# #################################################### #################################### # +# ################################# #################################################### #################################### # +# ################################# #################################################### #################################### # +# ############################# #### #################### #################################### # +# ############################# #### #################### #################################### # +# ############################# #### #################### #################################### # +# ############################# #### #################### #################################### # +# ############################# ################################ # +# ############################# ################################ # +# ############################# ################################ # +# ############################# ################################ # +# ################################# ################################ # +# ################################# ################################ # +# ################################# ################################ # +# ################################# ################################ # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# #################################### # +# ############################# ######################################### # +# ############################# ######################################### # +# ############################# ######################################### # +# ############################# ######################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ##################################### # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ################################# ##################################### # +# ################################# ##################################### # +# ################################# ##################################### # +# ################################# ##################################### # +# ################################# ##################################### # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ################################# ##################################### # +# ################################# ##################################### # +# ################################# ##################################### # +# ################################# ##################################### # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ############################# ################################# # +# ################################# ################################# # +# ################################# ################################# # +# ################################# ################################# # +# ################################# ################################# # +# ############################ ##################################### # +# ############################ ##################################### # +# ############################ ##################################### # +# ############################ ##################################### # +# ################################ ################################# # +# ################################ ################################# # +# ################################ ################################# # +# ################################ ################################# # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ################################ ##################################### # +# ############################ ################################# # +# ############################ ################################# # +# ############################ ################################# # +# ############################ ################################# # +# ############################ #### ################################# # +# ############################ #### ################################# # +# ############################ #### ################################# # +# ############################ #### ################################# # +# ############################ ################# ################################# # +# ############################ ################# ################################# # +# ############################ ################# ################################# # +# ############################ ################# ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ################################# # +# ############################ ##################### ######## ################################# # +# ############################ ##################### ######## ################################# # +# ############################ ##################### ######## ################################# # +# ############################ ##################### ######## ################################# # +# ######################## #################### #################### ############################# # +# ######################## #################### #################### ############################# # +# ######################## #################### #################### ############################# # +# ######################## #################### #################### ############################# # +# ############################ #################### #################### ################################# # +# ############################ #################### #################### ################################# # +# ############################ #################### #################### ################################# # +# ############################ #################### #################### ################################# # +# ######################## #################### #################### ############################ # +# ######################## #################### #################### ############################ # +# ######################## #################### #################### ############################ # +# ######################## #################### #################### ############################ # +# ######################## ######################## ######################## ############################ #################### #### # +# ######################## ######################## ######################## ############################ #################### #### # +# ######################## ######################## ######################## ############################ #################### #### # +# ######################## ######################## ######################## ############################ #################### #### # +# ######################## ######################## ######################## ######################## ############################################ # +# ######################## ######################## ######################## ######################## ############################################ # +# ######################## ######################## ######################## ######################## ############################################ # +# ######################## ######################## ######################## ######################## ############################################ # +# ######################## ######################## ######################## ############################ ######################################################## # +# ######################## ######################## ######################## ############################ ######################################################## # +# ######################## ######################## ######################## ############################ ######################################################## # +# ######################## ######################## ######################## ############################ ######################################################## # +# ######################## #################### ############################ ############################ ######################## #### ################################ # +# ######################## #################### ############################ ############################ ######################## #### ################################ # +# ######################## #################### ############################ ############################ ######################## #### ################################ # +# ######################## #################### ############################ ############################ ######################## #### ################################ # +# ######################## #################### ######################## ############################ ######################## ############################ # +# ######################## #################### ######################## ############################ ######################## ############################ # +# ######################## #################### ######################## ############################ ######################## ############################ # +# ######################## #################### ######################## ############################ ######################## ############################ # +# ######################## ######################## ############################ ############################ ############################ ######################## # +# ######################## ######################## ############################ ############################ ############################ ######################## # +# ######################## ######################## ############################ ############################ ############################ ######################## # +# ######################## ######################## ############################ ############################ ############################ ######################## # +# #################### #################### ############################ ######################## ############################# ######################## # +# #################### #################### ############################ ######################## ############################# ######################## # +# #################### #################### ############################ ######################## ############################# ######################## # +# #################### #################### ############################ ######################## ############################# ######################## # +# #################### #################### ######################## ######################## ############################# ######################## # +# #################### #################### ######################## ######################## ############################# ######################## # +# #################### #################### ######################## ######################## ############################# ######################## # +# #################### #################### ######################## ######################## ############################# ######################## # +# ######################## #################### ############################ ############################ ################################# ######################## # +# ######################## #################### ############################ ############################ ################################# ######################## # +# ######################## #################### ############################ ############################ ################################# ######################## # +# ######################## #################### ############################ ############################ ################################# ######################## # +# ######################## #################### ######################## ############################ ################################# ######################## # +# ######################## #################### ######################## ############################ ################################# ######################## # +# ######################## #################### ######################## ############################ ################################# ######################## # +# ######################## #################### ######################## ############################ ################################# ######################## # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### #################### ######################## ############################ ################################# #################### # +# #################### ################ #################### ######################## ################################# #################### # +# #################### ################ #################### ######################## ################################# #################### # +# #################### ################ #################### ######################## ################################# #################### # +# #################### ################ #################### ######################## ################################# #################### # +# #################### ################ ######################## ######################## ################################# ################ # +# #################### ################ ######################## ######################## ################################# ################ # +# #################### ################ ######################## ######################## ################################# ################ # +# #################### ################ ######################## ######################## ################################# ################ # +# #################### ################ #################### ############################ ##################################### #################### # +# #################### ################ #################### ############################ ##################################### #################### # +# #################### ################ #################### ############################ ##################################### #################### # +# #################### ################ #################### ############################ ##################################### #################### # +# #################### #################### #################### ############################ #################################### #################### # +# #################### #################### #################### ############################ #################################### #################### # +# #################### #################### #################### ############################ #################################### #################### # +# #################### #################### #################### ############################ #################################### #################### # +# #################### #################### ######################## ######################## #################################### #################### # +# #################### #################### ######################## ######################## #################################### #################### # +# #################### #################### ######################## ######################## #################################### #################### # +# #################### #################### ######################## ######################## #################################### #################### # +# #################### ################ #################### ############################ #################################### #################### # +# #################### ################ #################### ############################ #################################### #################### # +# #################### ################ #################### ############################ #################################### #################### # +# #################### ################ #################### ############################ #################################### #################### # +# #################### ################ ######################### ############################ ################################ #################### # +# #################### ################ ######################### ############################ ################################ #################### # +# #################### ################ ######################### ############################ ################################ #################### # +# #################### ################ ######################### ############################ ################################ #################### # +# #################### ################ ##################### ############################ ################################ #################### # +# #################### ################ ##################### ############################ ################################ #################### # +# #################### ################ ##################### ############################ ################################ #################### # +# #################### ################ ##################### ############################ ################################ #################### # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ################ ######################### ############################ ################################ ################ # +# #################### ################ ######################### ############################ ################################ ################ # +# #################### ################ ######################### ############################ ################################ ################ # +# #################### ################ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ ################################ ################ # +# #################### ############ ######################### ############################ #### ######################################## ################################ #################### # +# #################### ############ ######################### ############################ #### ######################################## ################################ #################### # +# #################### ############ ######################### ############################ #### ######################################## ################################ #################### # +# #################### ############ ######################### ############################ #### ######################################## ################################ #################### # +# #################### ############ ##################### ############################ ############################################################################################# ############################ #################### # +# #################### ############ ##################### ############################ ############################################################################################# ############################ #################### # +# #################### ############ ##################### ############################ ############################################################################################# ############################ #################### # +# #################### ############ ##################### ############################ ############################################################################################# ############################ #################### # +# #################### ############ ######################### ############################ #### ############################################################################################################# ################################ #################### # +# #################### ############ ######################### ############################ #### ############################################################################################################# ################################ #################### # +# #################### ############ ######################### ############################ #### ############################################################################################################# ################################ #################### # +# #################### ############ ######################### ############################ #### ############################################################################################################# ################################ #################### # +# #################### ############ ##################### ################################ ##################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ################################ ##################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ################################ ##################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ################################ ##################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ################################################################################################################################################################################## ############################ #################### # +# #################### ############ ##################### ################################################################################################################################################################################## ############################ #################### # +# #################### ############ ##################### ################################################################################################################################################################################## ############################ #################### # +# #################### ############ ##################### ################################################################################################################################################################################## ############################ #################### # +# #################### ############ ##################### ###################################################################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ###################################################################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ###################################################################################################################################################################################### ############################ #################### # +# #################### ############ ##################### ###################################################################################################################################################################################### ############################ #################### # +# ######################## ################ ##################### ######################################################## ######################################################### ############################ ######################## # +# ######################## ################ ##################### ######################################################## ######################################################### ############################ ######################## # +# ######################## ################ ##################### ######################################################## ######################################################### ############################ ######################## # +# ######################## ################ ##################### ######################################################## ######################################################### ############################ ######################## # +# #################### ############ ######################### ######################################## ################################################# ############################ ######################## # +# #################### ############ ######################### ######################################## ################################################# ############################ ######################## # +# #################### ############ ######################### ######################################## ################################################# ############################ ######################## # +# #################### ############ ######################### ######################################## ################################################# ############################ ######################## # +# #################### ############ ######################### ################################ ######################################### ############################ ######################## # +# #################### ############ ######################### ################################ ######################################### ############################ ######################## # +# #################### ############ ######################### ################################ ######################################### ############################ ######################## # +# #################### ############ ######################### ################################ ######################################### ############################ ######################## # +# ######################## ################ #################### ######################## ############ ############################################################# ############################ # +# ######################## ################ #################### ######################## ############ ############################################################# ############################ # +# ######################## ################ #################### ######################## ############ ############################################################# ############################ # +# ######################## ################ #################### ######################## ############ ############################################################# ############################ # +# #################### ############ #################### ######################## #################### ################################################# ############################ # +# #################### ############ #################### ######################## #################### ################################################# ############################ # +# #################### ############ #################### ######################## #################### ################################################# ############################ # +# #################### ############ #################### ######################## #################### ################################################# ############################ # +# #################### ############ #################### #################### ######################## ##################################### ############################ # +# #################### ############ #################### #################### ######################## ##################################### ############################ # +# #################### ############ #################### #################### ######################## ##################################### ############################ # +# #################### ############ #################### #################### ######################## ##################################### ############################ # +# ######################## ############ #################### #################### ############################ ############################ ################################ # +# ######################## ############ #################### #################### ############################ ############################ ################################ # +# ######################## ############ #################### #################### ############################ ############################ ################################ # +# ######################## ############ #################### #################### ############################ ############################ ################################ # +# ######################## ############ #################### #### ######################## #################### ################################# # +# ######################## ############ #################### #### ######################## #################### ################################# # +# ######################## ############ #################### #### ######################## #################### ################################# # +# ######################## ############ #################### #### ######################## #################### ################################# # +# #################### ############ ################ ######################## ######################### ################################# # +# #################### ############ ################ ######################## ######################### ################################# # +# #################### ############ ################ ######################## ######################### ################################# # +# #################### ############ ################ ######################## ######################### ################################# # +# #################### ############ ################ ######## ######################### ##################################### # +# #################### ############ ################ ######## ######################### ##################################### # +# #################### ############ ################ ######## ######################### ##################################### # +# #################### ############ ################ ######## ######################### ##################################### # +# #################### ############ ############ ######################### ##################################### # +# #################### ############ ############ ######################### ##################################### # +# #################### ############ ############ ######################### ##################################### # +# #################### ############ ############ ######################### ##################################### # +# ######################## ################ ############ ############################################################ ######################### ##################################### # +# ######################## ################ ############ ############################################################ ######################### ##################################### # +# ######################## ################ ############ ############################################################ ######################### ##################################### # +# ######################## ################ ############ ############################################################ ######################### ##################################### # +# ######################## ################ ############ ############################################################ ######################### ##################################### # +# ######################## ############ ############ ############################################################ ####################### ##################################### # +# ######################## ############ ############ ################################################################################################################# ######################################### # +# ######################## ############ ############ ################################################################################################################# ######################################### # +# ######################## ############ ############ ################################################################################################################# ######################################### # +# ######################## ################ ################ ########################################################################################################################## ##################################### # +# ######################## ################ ################ ########################################################################################################################## ##################################### # +# ######################## ################ ################ ########################################################################################################################## ##################################### # +# ######################## ################ ################ ########################################################################################################################## ##################################### # +# ######################## ################ ############ ########################################################################################################################################## ##################################### # +# ######################## ################ ############ ########################################################################################################################################## ##################################### # +# ######################## ################ ############ ########################################################################################################################################## ##################################### # +# ######################## ################ ############ ########################################################################################################################################## ##################################### # +# ######################## ################ ################ ################################################################################################################################################## ############################################# # +# ######################## ################ ################ ################################################################################################################################################## ############################################# # +# ######################## ################ ################ ################################################################################################################################################## ############################################# # +# ######################## ################ ################ ################################################################################################################################################## ############################################# # +# ######################## ################ ################# ################################################################################################################################################## ######################################### # +# ######################## ################ ################# ################################################################################################################################################## ######################################### # +# ######################## ################ ################# ################################################################################################################################################## ######################################### # +# ######################## ################ ################# ################################################################################################################################################## ######################################### # +# ######################## ######## ################# ##### #### #### ############################################################################# ##################################### # +# ######################## ######## ################# ##### #### #### ############################################################################# ##################################### # +# ######################## ######## ################# ##### #### #### ############################################################################# ##################################### # +# ######################## ######## ################# ##### #### #### ############################################################################# ##################################### # +# #################### ######## ################# #### ############################################################# ######################################### # +# #################### ######## ################# #### ############################################################# ######################################### # +# #################### ######## ################# #### ############################################################# ######################################### # +# #################### ######## ################# #### ############################################################# ######################################### # +# ######################## ############ ################# ##################################################### ##################################### # +# ######################## ############ ################# ##################################################### ##################################### # +# ######################## ############ ################# ##################################################### ##################################### # +# ######################## ############ ################# ##################################################### ##################################### # +# ######################## ######## ############ ############# ##################################################### ##################################### # +# ######################## ######## ############ ############# ##################################################### ##################################### # +# ######################## ######## ############ ############# ##################################################### ##################################### # +# ######################## ######## ############ ############# ##################################################### ##################################### # +# ######################## ######## ################ ################# ################################################# ############################################# # +# ######################## ######## ################ ################# ################################################# ############################################# # +# ######################## ######## ################ ################# ################################################# ############################################# # +# ######################## ######## ################ ################# ################################################# ############################################# # +# ######################## ################ ######## ######################## ################# ############ ############################ #### ############################ # +# ######################## ################ ######## ######################## ################# ############ ############################ #### ############################ # +# ######################## ################ ######## ######################## ################# ############ ############################ #### ############################ # +# ######################## ################ ######## ######################## ################# ############ ############################ #### ############################ # +# ######################### ######################################## ############################ ################# ######################################## ######################## # +# ######################### ######################################## ############################ ################# ######################################## ######################## # +# ######################### ######################################## ############################ ################# ######################################## ######################## # +# ######################### ######################################## ############################ ################# ######################################## ######################## # +# ######################### ######################################## ################################ ############# ######################################## #################### # +# ######################### ######################################## ################################ ############# ######################################## #################### # +# ######################### ######################################## ################################ ############# ######################################## #################### # +# ######################### ######################################## ################################ ############# ######################################## #################### # +# ############################# ################################ ##################################################### ######################################## ######################## # +# ############################# ################################ ##################################################### ######################################## ######################## # +# ############################# ################################ ##################################################### ######################################## ######################## # +# ############################# ################################ ##################################################### ######################################## ######################## # +# ######################### ################ #################### ######################### ######################################## #################### # +# ######################### ################ #################### ######################### ######################################## #################### # +# ######################### ################ #################### ######################### ######################################## #################### # +# ######################### ################ #################### ######################### ######################################## #################### # +# ############################# ################ #################### ##################### ################ #################################### #################### # +# ############################# ################ #################### ##################### ################ #################################### #################### # +# ############################# ################ #################### ##################### ################ #################################### #################### # +# ############################# ################ #################### ##################### ################ #################################### #################### # +# ############################# ############################################ ############ #################### ######################################## ################ # +# ############################# ############################################ ############ #################### ######################################## ################ # +# ############################# ############################################ ############ #################### ######################################## ################ # +# ############################# ############################################ ############ #################### ######################################## ################ # +# ############################# #################################### #################### #################################### #################### # +# ############################# #################################### #################### #################################### #################### # +# ############################# #################################### #################### #################################### #################### # +# ############################# #################################### #################### #################################### #################### # +# ################################# ############################ ######################## ################################ #### ################ # +# ################################# ############################ ######################## ################################ #### ################ # +# ################################# ############################ ######################## ################################ #### ################ # +# ################################# ############################ ######################## ################################ #### ################ # +# ############################# #################### ######################## #################################### ##################### ############################ # +# ############################# #################### ######################## #################################### ##################### ############################ # +# ############################# #################### ######################## #################################### ##################### ############################ # +# ############################# #################### ######################## #################################### ##################### ############################ # +# ################################# ######## #################### #################################### ############################################# # +# ################################# ######## #################### #################################### ############################################# # +# ################################# ######## #################### #################################### ############################################# # +# ################################# ######## #################### #################################### ############################################# # +# ################################# ################################ ################################# # +# ################################# ################################ ################################# # +# ################################# ################################ ################################# # +# ################################# ################################ ################################# # +# ################################# ################################ ################# # +# ################################# ################################ ################# # +# ################################# ################################ ################# # +# ################################# ################################ ################# # +# ################################# #################################### ################ # +# ################################# #################################### ################ # +# ################################# #################################### ################ # +# ################################# #################################### ################ # +# ##################################### ############################ #################### # +# ##################################### ############################ #################### # +# ##################################### ############################ #################### # +# ##################################### ############################ #################### # +# ################################# ################################ ################ # +# ################################# ################################ ################ # +# ################################# ################################ ################ # +# ################################# ################################ ################ # +# ##################################### ################################ #################### # +# ##################################### ################################ #################### # +# ##################################### ################################ #################### # +# ##################################### ################################ #################### # +# #################################### ################# ################################ #################### # +# #################################### ################# ################################ #################### # +# #################################### ################# ################################ #################### # +# #################################### ################# ################################ #################### # +# ################################ ##################### ######################## #################### # +# ################################ ##################### ######################## #################### # +# ################################ ##################### ######################## #################### # +# ################################ ##################### ######################## #################### # +# ################################ ##################### ######################## #################### # +# ################################ ##################### ################################ ################ # +# ################################ ##################### ################################ ################ # +# ################################ ##################### ################################ ################ # +# ################################ ##################### ################################ ################ # +# ################################ ##################### ############################ ################ # +# ################################ ##################### ############################ ################ # +# ################################ ##################### ############################ ################ # +# ################################ ##################### ############################ ################ # +# #################################### ######################### ############################ ################ # +# #################################### ######################### ############################ ################ # +# #################################### ######################### ############################ ################ # +# #################################### ######################### ############################ ################ # +# #################################### ################# ######################## ################ # +# #################################### ################# ######################## ################ # +# #################################### ################# ######################## ################ # +# #################################### ################# ######################## ################ # +# #################################### ######## ############################ ################ # +# #################################### ######## ############################ ################ # +# #################################### ######## ############################ ################ # +# #################################### ######## ############################ ################ # +# ################################ ############################ #################### # +# ################################ ############################ #################### # +# ################################ ############################ #################### # +# ################################ ############################ #################### # +# #################################### ######################################## ################ # +# #################################### ######################################## ################ # +# #################################### ######################################## ################ # +# #################################### ######################################## ################ # +# ######################################## #################################################### #### ##### ######################## # +# ######################################## #################################################### #### ##### ######################## # +# ######################################## #################################################### #### ##### ######################## # +# ######################################## #################################################### #### ##### ######################## # +# ######################################## #### ############################################################################################################# # +# ######################################## #### ############################################################################################################# # +# ######################################## #### ############################################################################################################# # +# ######################################## #### ############################################################################################################# # +# ################################################ ################# ############################################################################################################# # +# ################################################ ################# ############################################################################################################# # +# ################################################ ################# ############################################################################################################# # +# ################################################ ################# ############################################################################################################# # +# ############################################################ ######### ######## ######################## ############################################################################# # +# ############################################################ ######### ######## ######################## ############################################################################# # +# ############################################################ ######### ######## ######################## ############################################################################# # +# ############################################################ ######### ######## ######################## ############################################################################# # +# #################################################################### ######################### ######################## ############################################# # +# #################################################################### ######################### ######################## ############################################# # +# #################################################################### ######################### ######################## ############################################# # +# #################################################################### ######################### ######################## ############################################# # +# ################ #################### ######################################## ##################### ############################ # +# ################ #################### ######################################## ##################### ############################ # +# ################ #################### ######################################## ##################### ############################ # +# ################ #################### ######################################## ##################### ############################ # +# #################### ######################## ############################################# ############################ # +# #################### ######################## ############################################# ############################ # +# #################### ######################## ############################################# ############################ # +# #################### ######################## ############################################# ############################ # +# ################################ ############################ ################################################# ################################ # +# ################################ ############################ ################################################# ################################ # +# ################################ ############################ ################################################# ################################ # +# ################################ ############################ ################################################# ################################ # +# #################################### ######################## ##################################################### ############################ # +# #################################### ######################## ##################################################### ############################ # +# #################################### ######################## ##################################################### ############################ # +# #################################### ######################## ##################################################### ############################ # +# ############ ################ ######################## ################################################################# ################################ # +# ############ ################ ######################## ################################################################# ################################ # +# ############ ################ ######################## ################################################################# ################################ # +# ############ ################ ######################## ################################################################# ################################ # +# ############ ######################## ############################ ############################################################################# ################################# # +# ############ ######################## ############################ ############################################################################# ################################# # +# ############ ######################## ############################ ############################################################################# ################################# # +# ############ ######################## ############################ ############################################################################# ################################# # +# ############ #################### ############################ #################### ################################################################# ##################################### # +# ############ #################### ############################ #################### ################################################################# ##################################### # +# ############ #################### ############################ #################### ################################################################# ##################################### # +# ############ #################### ############################ #################### ################################################################# ##################################### # +# ############ #################### ######################## #################### ############################################################################ #### ############ ################################# # +# ############ #################### ######################## #################### ############################################################################ #### ############ ################################# # +# ############ #################### ######################## #################### ############################################################################ #### ############ ################################# # +# ############ #################### ######################## #################### ############################################################################ #### ############ ################################# # +# ################ #################### ######################## #################### #################################################################################### ############ ################################# # +# ################ #################### ######################## #################### #################################################################################### ############ ################################# # +# ################ #################### ######################## #################### #################################################################################### ############ ################################# # +# ################ #################### ######################## #################### #################################################################################### ############ ################################# # +# ############ #################### #################### #################### ################################################################################################ ############ ################################# # +# ############ #################### #################### #################### ################################################################################################ ############ ################################# # +# ############ #################### #################### #################### ################################################################################################ ############ ################################# # +# ############ #################### #################### #################### ################################################################################################ ############ ################################# # +# ############ ################ ############################ #################### ############################################################################################# ######## ##################################### # +# ############ ################ ############################ #################### ############################################################################################# ######## ##################################### # +# ############ ################ ############################ #################### ############################################################################################# ######## ##################################### # +# ############ ################ ############################ #################### ############################################################################################# ######## ##################################### # +# ############ #################### ######################## ######################## ################################################################################################# ######## ##################################### # +# ############ #################### ######################## ######################## ################################################################################################# ######## ##################################### # +# ############ #################### ######################## ######################## ################################################################################################# ######## ##################################### # +# ############ #################### ######################## ######################## ################################################################################################# ######## ##################################### # +# ############ ############################################# ######################## ##################################################################################### #################################### # +# ############ ############################################# ######################## ##################################################################################### #################################### # +# ############ ############################################# ######################## ##################################################################################### #################################### # +# ############ ############################################# ######################## ##################################################################################### #################################### # +# ############ ##################################### #################### ######################################################################### #################################### #################################### # +# ############ ##################################### #################### ######################################################################### #################################### #################################### # +# ############ ##################################### #################### ######################################################################### #################################### #################################### # +# ############ ##################################### #################### ######################################################################### #################################### #################################### # +# ################ ############################# #################### ######################################################### ############################################################ ############################################ # +# ################ ############################# #################### ######################################################### ############################################################ ############################################ # +# ################ ############################# #################### ######################################################### ############################################################ ############################################ # +# ################ ############################# #################### ######################################################### ############################################################ ############################################ # +# ############ ##################### ######################## ##################################### ############################################################################################# #################################################### # +# ############ ##################### ######################## ##################################### ############################################################################################# #################################################### # +# ############ ##################### ######################## ##################################### ############################################################################################# #################################################### # +# ############ ##################### ######################## ##################################### ############################################################################################# #################################################### # +# ############ ############# ################ ################################# ######################################################################################################################################################### # +# ############ ############# ################ ################################# ######################################################################################################################################################### # +# ############ ############# ################ ################################# ######################################################################################################################################################### # +# ############ ############# ################ ################################# ######################################################################################################################################################### # +# ############ ############# ################ ################################# ######################################################################################################################################################### # +# ################ ######################## ############################# ##################################################################################################################################################### # +# ################ ######################## ############################# ##################################################################################################################################################### # +# ################ ######################## ############################# ##################################################################################################################################################### # +# ################ ######################## ############################# ##################################################################################################################################################### # +# ############ ######################## ############################# #################### ################################################################################################# # +# ############ ######################## ############################# #################### ################################################################################################# # +# ############ ######################## ############################# #################### ################################################################################################# # +# ############ ######################## ############################# #################### ################################################################################################# # +# ############ ######################## ############ ############################# ######################## ##################################################################### # +# ############ ######################## ############ ############################# ######################## ##################################################################### # +# ############ ######################## ############ ############################# ######################## ##################################################################### # +# ############ ######################## ############ ############################# ######################## ##################################################################### # +# ################ ######################## #################################### ############################# #################### #### #################################### # +# ################ ######################## #################################### ############################# #################### #### #################################### # +# ################ ######################## #################################### ############################# #################### #### #################################### # +# ################ ######################## #################################### ############################# #################### #### #################################### # +# ################ ######################## ##################################################################################### #################### # +# ################ ######################## ##################################################################################### #################### # +# ################ ######################## ##################################################################################### #################### # +# ################ ######################## ##################################################################################### #################### # +# ################ ######################## ##################################################################################### ######################## # +# ################ ######################## ##################################################################################### ######################## # +# ################ ######################## ##################################################################################### ######################## # +# ################ ######################## ##################################################################################### ######################## # +# ############ ######################## ##################################################################################### #################### # +# ############ ######################## ##################################################################################### #################### # +# ############ ######################## ##################################################################################### #################### # +# ############ ######################## ##################################################################################### #################### # +# ################ ######################## ##################################################################################### ################ # +# ################ ######################## ##################################################################################### ################ # +# ################ ######################## ##################################################################################### ################ # +# ################ ######################## ##################################################################################### ################ # +# ############ ############################ ######################## ##################################################### ################ # +# ############ ############################ ######################## ##################################################### ################ # +# ############ ############################ ######################## ##################################################### ################ # +# ############ ############################ ######################## ##################################################### ################ # +# ############ ######################## ######################## ######################################## ################ # +# ############ ######################## ######################## ######################################## ################ # +# ############ ######################## ######################## ######################################## ################ # +# ############ ######################## ######################## ######################################## ################ # +# ############ ############################# #################### ################################ ################ # +# ############ ############################# #################### ################################ ################ # +# ############ ############################# #################### ################################ ################ # +# ############ ############################# #################### ################################ ################ # +# ################ ############################# ######################## ######################## #################### # +# ################ ############################# ######################## ######################## #################### # +# ################ ############################# ######################## ######################## #################### # +# ################ ############################# ######################## ######################## #################### # +# ##################################################### ######################## ######## #################### # +# ##################################################### ######################## ######## #################### # +# ##################################################### ######################## ######## #################### # +# ##################################################### ######################## ######## #################### # +# ############################################# ############################ #################### # +# ############################################# ############################ #################### # +# ############################################# ############################ #################### # +# ############################################# ############################ #################### # +# ##################################### ############################ ################ # +# ##################################### ############################ ################ # +# ##################################### ############################ ################ # +# ##################################### ############################ ################ # +# ############################# ############################ ################ # +# ############################# ############################ ################ # +# ############################# ############################ ################ # +# ############################# ############################ ################ # +# #################### ######################## #################### # +# #################### ######################## #################### # +# #################### ######################## #################### # +# #################### ######################## #################### # +# ############ ######################## ################ # +# ############ ######################## ################ # +# ############ ######################## ################ # +# ############ ######################## ################ # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ #################### # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ######################## ################ # +# ######################## ################ # +# ######################## ################ # +# ######################## ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ############################ ################ # +# ######################## #################### # +# ######################## #################### # +# ######################## #################### # +# ######################## #################### # +# #################### #################### # +# #################### #################### # +# #################### #################### # +# #################### #################### # +# ######################## ######################### # +# ######################## ######################### # +# ######################## ######################### # +# ######################## ######################### # +# ######################## ######################### # +# ############################################################# # +# ############################################################# # +# ############################################################# # +# ############################################################# # +# ##################################################### # +# ##################################################### # +# ##################################################### # +# ##################################################### # +# ################################################# # +# ################################################# # +# ################################################# # +# ################################################# # +# ##################################### # +# ##################################### # +# ##################################### # +# ##################################### # +# ##################################### # +# ##################################### # +# ##################################### # +# ##################################### # +# ######################### # +# ######################### # +# ######################### # +# ######################### # +# ############ # +# ############ # +# ############ # +# ############ # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +# # +################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################ +>"d"55+*:2**1- >:"#"\:"d"55+2**%\"d"55+2**/1+p:#v_ "d"55+*:2*:10p v +^ ^ -1< v p05+1*+:5g01p11p10:" "p032p00*p02: 030p 040p>30g1+:30p:10g% \10g/1+g"X"-| +v < _^#`g03g00 <| - g03g00 < p04+g04 g03< +> "X" 30g:10g%\10g/1+p30g >30g+ : 00g\` #v_$>30g1+:30p:10g%\10g/1+g" "- |>40g.@ + ^p+1/g01\%g01:\" ":< ^ < \ No newline at end of file diff --git a/www/data/blog/Befunge_1/Euler_Problem-11.b93 b/www/data/blog/Befunge_1/Euler_Problem-11.b93 new file mode 100644 index 0000000..eb55da7 --- /dev/null +++ b/www/data/blog/Befunge_1/Euler_Problem-11.b93 @@ -0,0 +1,31 @@ +v v < +>"4"2/:*1-00p > 000g: "4"2/ %"?"+\ "4"2/ /1+ p 00g:1-00p #^_v++++++++++++++++++++++++++ + ++++++++++++++++++++++++++ + ++++++++++++++++++++++++++ + 08 02 22 97 38 15 00 40 00 75 04 05 07 78 52 12 50 77 91 08 | +++####################+++ + 49 49 99 40 17 81 18 57 60 87 17 40 98 43 69 48 04 56 62 00 | +++####################+++ + 81 49 31 73 55 79 14 29 93 71 40 67 53 88 30 03 49 13 36 65 | +++####################+++ + 52 70 95 23 04 60 11 42 69 24 68 56 01 32 56 71 37 02 36 91 | +++####################+++ + 22 31 16 71 51 67 63 89 41 92 36 54 22 40 40 28 66 33 13 80 | +++####################+++ + 24 47 32 60 99 03 45 02 44 75 33 53 78 36 84 20 35 17 12 50 | +++####################+++ + 32 98 81 28 64 23 67 10 26 38 40 67 59 54 70 66 18 38 64 70 | +++####################+++ + 67 26 20 68 02 62 12 20 95 63 94 39 63 08 40 91 66 49 94 21 | +++####################+++ + 24 55 58 05 66 73 99 26 97 17 78 78 96 83 14 88 34 89 63 72 | +++####################+++ + 21 36 23 09 75 00 76 44 20 45 35 14 00 61 33 97 34 31 33 95 | +++####################+++ + 78 17 53 28 22 75 31 67 15 94 03 80 04 62 16 14 09 53 56 92 | +++####################+++ + 16 39 05 42 96 35 31 47 55 58 88 24 00 17 54 24 36 29 85 57 | +++####################+++ + 86 56 00 48 35 71 89 07 05 44 44 37 44 60 21 58 51 54 17 58 | +++####################+++ + 19 80 81 68 05 94 47 69 28 73 92 13 86 52 17 77 04 89 55 40 | +++####################+++ + 04 52 08 83 97 35 99 16 07 97 57 32 16 26 26 79 33 27 98 66 | +++####################+++ + 88 36 68 87 57 62 20 72 03 46 33 67 46 55 12 32 63 93 53 69 | +++####################+++ + 04 42 16 73 38 25 39 11 24 94 72 18 08 46 29 32 40 62 76 36 | +++####################+++ + 20 69 36 41 72 30 23 88 34 62 99 69 82 67 59 85 74 04 36 16 | +++####################+++ + 20 73 35 29 78 31 90 01 74 31 49 71 48 86 81 16 23 57 05 54 | +++####################+++ + 01 70 54 71 83 51 54 69 16 92 33 48 61 43 52 01 89 19 67 48 | +++####################+++ +vp00-1*:*45 p1++1550p0++1551p1+55-10p0+551p19-10p090 p010<++++++++++++++++++++++++++ >10pv +>00g:54*%3*1+\54*/4+g"0"-52**00g:54*%3*2+\54*/4+g"0"-+00g:54*%v++++++++++++++++++++++++++ >$> v +| p00-1:g00p+4/*45\+"B"<++++++++++++++++++++++++++ ^_^#`g01:< v < +>54*:*1-00p>220p>20g9+:0g30p1g40p00g:54*%50p54*/60p50g"B"+60g4+g50g30g+50p60g40g+60p>50g"B"+60g4+g50g30g+50p60g40g+60pv >20g:1-20p#v_00g:1-00p#^_10g. @ + ^ _^# 50g"B"+60g4+g50g30g+50p60g40g+60p***^ + ^ << \ No newline at end of file diff --git a/www/data/programs/desc/BefunGen/02_TextFunge/01_Language.markdown b/www/data/programs/desc/BefunGen/02_TextFunge/01_Language.markdown index e69de29..42ca36d 100644 --- a/www/data/programs/desc/BefunGen/02_TextFunge/01_Language.markdown +++ b/www/data/programs/desc/BefunGen/02_TextFunge/01_Language.markdown @@ -0,0 +1,478 @@ +TextFunge is the c-like language used for BefunGen. +Most constructs are very similar to C and Pascal, so you won't have trouble writing anything in it. + +> *Note:* +> TexFunge programs are case-insensitive. *(but please be consistent with your naming)* + +###Program structure + +A TextFunge program starts with the keyword `program` and the program name and ends with `end` + +```textfunge +program example_01 : display[0, 0] + begin + // code + end + + void method() + begin + // code + end +end +``` + +between program` and `end` you can put your methods. The first method has no header and is called the main method. +This method is called upon the beginning and when this method has finished the program terminates. + +You can specify a display by writing `: display[width, height]`, if the display is not specified its has a width and height of zero. + +###Types + +TextFunge knows 9 different variable types: + + - Integer: A single integer value + - Digit: A single Base-10 digit (integer in the range from `0` to `9` ) + - Character: A single character + - Boolean: A boolean value (`TRUE` or `FALSE`) + - Void: Nothing, used for methods that return nothing + - Integer Array: An fixed-length array of multiple integer + - String: An fixed-length array of multiple character + - Digit Array: An fixed-length array of multiple digits + - Boolean Array: An fixed-length array of multiple booleans + +```textfunge +int a1; +integer a2; +int[4] a3; + +char b1; +character b2; +character[4] b3; + +bool c1; +boolean c2; +bool[4] c3; + +digit d1; +digit[4] d2; +``` + +You can freely cast all value types into each other and all array-types with the same length (see *Casts* for more information) + +###Variables + +Between each method header and the `begin` keyword you can specify local variables under the `var` keyword: + +```textfunge +void method() +var + int var_1, var_2; + int var_3 := 77; + int[4] var_4 := {0, 1, 1, 0}; + char[4] var_5 := "FFFF"; +begin +``` + +These variables have a local scope and can't be accessed from anywhere else. + +You can also at the beginning of the program specify variables with a global scope + +```textfunge +program example_02 +global + int gvar_1, gvar_2; + int gvar3; +``` + +> *Note:* +> Global variables (unlike local variables) can **not** have an initializer, they will initially have the value which you specified while compiling. + +To access a variable as whole just write its name, to access an specific array index write the index in square brackets: + +```textfunge +var_1[0] = var_2[4 + 1]; +``` + +###Constants + +At the same position as global variables can (global) constants be defined: + +```textfunge +program example_02 +const + int VERSION := 14; + int COL_BLUE := 0x0000FF; + char UNDERSCORE := '_'; +``` + +Be aware that constants are always in the compiled program inlined. +So constants are only *syntactical sugar* and result in the same as writing the literal everywhere, where you use the constant. + +> *Note:* +> You can only define constants for value types, array constants are not *yet* supported. + +###Literals + +You can specify (Base-10) integer literals by simply writing the number: + +```textfunge +0 +9283 +-9283 +``` + +And also Base-16 (Hexadecimal) integer literals with `0x` + +```textfunge +0x00 +0xF0F +0x123 +``` + +Digit literals have a `#` prefix: + +```textfunge +#0 +#6 +#9 +``` + +Char literals are surrounded by single ticks: + +```textfunge +' ' +'A' +'a' +``` + +Boolean literals consist of the two boolean keywords: + +```textfunge +true +false +TRUE +``` + +String literals are surrounded by quotation marks: (Be aware that a string literal is only a shortcut notation of an char array) + +```textfunge +"" +"hello" +"hello \r\n second line" +``` + +And Array literals are the values inside of a set of curly braces: + +```textfunge +{0, 1} +{'h', 'e', 'l', 'l', 'o'} +{true, false, true} +``` + +###Methods + +Methods consist of 2 parts, the header and the body: + +```textfunge +int[9] method(int a, int b, int[9] c) +var + int var_1 := 0; + int var_2; +begin + // Code + // Code + // Code + + return c; +end +``` + +In the header you define the return type (value type, array type or `void`), +the method name (the normal C naming restriction are valid) and the parameter list (multiple value or array types). + +Then you can (optionally) define local variables. + +And finally between `begin` and `end` you can write your code. + +> *Note:* +> Every path of an method must result in an `return` statement. +> If the return type is void the compiler can automatically add an return to the end. + + +###Control Structures + +#### If / Elsif + +```textfunge +if (a) then + // Code [a == true] +elsif (b) then + // Code [b == true] +elsif (c) then + // Code [c == true] +else + // Code [else] +end +``` + +You can write a branch statement with the keyword `if`. +Unlike C you have to write additional `else if`-branches with the keyword `elsif` and you have to end the whole block with `end` + +#### While do + +The `while` loop repeats a statement block until a condition is false + +```textfunge +while (running) do + // Code +end +``` + +Every loop the condition is evaluated and checked. + +#### Repeat until + +The `repeat until` loop repeats a statement block until a condition is true + +```textfunge +while (running) do + // Code +end +``` + +The difference to a `while` loop is that the condition is executed at least once. + +#### For + +The `for` loop is a more comfortable loop, because it has an initializer field, a condition field, and a statement field + +```textfunge +// (init ; cond ; stmt) +for (i = 0; i < 10; i++ ) do + // Code +end +``` + +Each field can also be empty, allowing for this simple, infinite loop: + +```textfunge +for (;;) do + // Code +end +// <-- unreachable (without goto) +``` + +#### Switch case + +If you want to distinct multiple values you can use a switch statement: + +```textfunge +switch(c) +begin + case ' ': + // Code + end + case '0': + // Code + end + default: + // Else-Code + end +end +``` + +> *Note:* +> This is **not** C, there is no fall-through with empty case blocks. + +> *Note:* +> Having a lot of cases in a single switch can increase the horizontal size of your program drastically. +> Think about using other possibilities in this case + +#### Goto + +```textfunge +goto MLBL; +out "Nobody sees me"; +MLBL: +out "end"; +``` + +You can define labels by writing the identifier and a colon (instead of a semicolon). +And you can write goto statements with the keyword `goto` + +> *Note:* +> This is **not** C, you have to end an goto statement with an semicolon, like every other statement too. + +> *Note:* +> Use goto's sparely, they are pretty slow and I'm not sure if they are bug-free. + +###Expressions +####Mathematical operators + +You can use the normal mathematical operators `+`, `-`, `*`, `/`, `%` (modulo), `(` and `)`. +Normal precedence rules apply + +```textfunge +a = ((5 + 5)*4 - 10)/-1 % 4; +``` + +####Boolean operators + +You can use the boolean operators `&&` (AND), `||` (OR), `^` (XOR), `!` (NOT). + +```textfunge +a = (10 == x) ^ true; +b = !(10 == x); +``` + +####Comparison + +You can use the normal c-like comparison operators `==`, `!=`, `<`, `>`, `<=` and `>=` + +```textfunge +while (a < 100 && a > -100) do + a *= 2; +end +``` + +###Special Statements + +####Random + +You can either generate a random boolean value by using `rand`, or a random integer value by using `rand[?]`. + +`rand[n]` generates a random number from [0, 4^n), where 0 is included and 4^n is excluded. So you are only able to set the upper border to results of the formula 4^n. + +```textfunge +if (rand) do + a = rand[6] % 10; +end +``` + +> *Note:* +> Be aware that in the example above not all values are equally distributed (4^6 % 10 != 0), but approximately it is good, and it becomes better with bigger values for n. + +####Quit + +The statement `quit`, `stop` or `close` instantly terminates the program. The main method will always implicitly have an `quit` at the end. + +```textfunge +if (error != 0) then + out "FATAL ERROR"; + quit; +end +``` + +####Code block + +You can start everywhere a new code block, it probably wont change the resulting program but has its use in structuring the source code. + +```textfunge +// Code +begin + // Code + // Code +end +// Code +``` + +####De-/Increment + +With `++` and `--` you can increment/decrement a variable in a shorter way than a assignment. + +```textfunge +a++; +a = a + 1; // equally +``` + +####Assignments + +With a single `=` you can assign a value to a variable. + +```textfunge +a = 3; +b[3] = 0; +``` + +###Method calls + +Method calls are pretty much like in every other language. + +```textfunge +method_1(0, 6, "hello"); +method_2(getA(), getB(0)); +``` + +###Comments + +You can write either full line comments with `//` or block comments with `/*` and `*/` + +```textfunge +/* Comment + * Comment + */ + +// Comment + +method_99( /* comment */ ); +``` + +###Casts + +TextFunge supports explicit and implicit casting. + +The cases in which implicit casts happen are: + + - `digit` -> `int` + - `digit[]` -> `int[]` (with same length) + +You can cast all other value types into each other and array types if they have the same length. + +```textfunge +var + bool b; + int i; + char c; +begin + c = (char)i; + b = (bool)c; +``` + +> *Note:* +> When casting no information is lost, so hard casting to an digit can yield to an illegal value. +> Also casting something from an boolean does not always result in `0` or `1` (it results in `0` / `not 0`). If you want this you can enable "explicit boolean casting" in the compiler options. + + +###Input/Output + +####Out + +With the statement `out` you can output either a value or a string: + +```textfunge +out 99; +out 'a'; +out "Hello World"; +out var_1; +``` + +####OutF + +`Outf` is a shortcut to writing multiple `out` statement. You can give it a comma-separated list of expressions to output + +```textfunge +out 99, 'a', "Hello World", var_1; +``` + +####In + +With the `In` Statement you can ask the user for a value, the input routine differs when you give it a integer variable or a character variable. + +``` +var + int var_1; + char var_2; +begin + in var_1; // Asks for number + in var_2; // Asks for character +``` \ No newline at end of file diff --git a/www/data/programs/desc/BefunGen/index.markdown b/www/data/programs/desc/BefunGen/index.markdown index fb34900..985f7d4 100644 --- a/www/data/programs/desc/BefunGen/index.markdown +++ b/www/data/programs/desc/BefunGen/index.markdown @@ -22,7 +22,7 @@ It's an IDE in which you can write a program in *TextFunge*, and compile it to v > **NOTE:** > > While the generated Code practically is Befunge-98, you can use it in nearly every Befunge-93 interpreter. -> Because it doesn't use a single command, which was not defined in Befunge-93, the only non-Befunge-93 feature is the extended filesize. +> Because it doesn't use a single command, which was not defined in Befunge-93, the only non-Befunge-93 feature is the extended file size. > Because this tool can generate fairly big Befunge-93 code, it often exceeds the size of 80x25, and is so no longer totally valid Befunge-93 code. > But for the sake of confusion I will refer in the rest of these documents to it as Befunge-93 code. diff --git a/www/javascript/prism.js b/www/javascript/prism.js index 46e36c8..b69ebc3 100644 --- a/www/javascript/prism.js +++ b/www/javascript/prism.js @@ -30,4 +30,9 @@ Prism.languages.sql={comment:{pattern:/(^|[^\\])(\/\*[\w\W]*?\*\/|((--)|(\/\/)|# * constant, builtin, variable, symbol, regex */Prism.languages.ruby=Prism.languages.extend("clike",{comment:/#[^\r\n]*(\r?\n|$)/g,keyword:/\b(alias|and|BEGIN|begin|break|case|class|def|define_method|defined|do|each|else|elsif|END|end|ensure|false|for|if|in|module|new|next|nil|not|or|raise|redo|require|rescue|retry|return|self|super|then|throw|true|undef|unless|until|when|while|yield)\b/g,builtin:/\b(Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Stat|File|Fixnum|Fload|Hash|Integer|IO|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|String|Struct|TMS|Symbol|ThreadGroup|Thread|Time|TrueClass)\b/,constant:/\b[A-Z][a-zA-Z_0-9]*[?!]?\b/g});Prism.languages.insertBefore("ruby","keyword",{regex:{pattern:/(^|[^/])\/(?!\/)(\[.+?]|\\.|[^/\r\n])+\/[gim]{0,3}(?=\s*($|[\r\n,.;})]))/g,lookbehind:!0},variable:/[@$]+\b[a-zA-Z_][a-zA-Z_0-9]*[?!]?\b/g,symbol:/:\b[a-zA-Z_][a-zA-Z_0-9]*[?!]?\b/g});; Prism.languages.csharp=Prism.languages.extend("clike",{keyword:/\b(abstract|as|base|bool|break|byte|case|catch|char|checked|class|const|continue|decimal|default|delegate|do|double|else|enum|event|explicit|extern|false|finally|fixed|float|for|foreach|goto|if|implicit|in|int|interface|internal|is|lock|long|namespace|new|null|object|operator|out|override|params|private|protected|public|readonly|ref|return|sbyte|sealed|short|sizeof|stackalloc|static|string|struct|switch|this|throw|true|try|typeof|uint|ulong|unchecked|unsafe|ushort|using|virtual|void|volatile|while|add|alias|ascending|async|await|descending|dynamic|from|get|global|group|into|join|let|orderby|partial|remove|select|set|value|var|where|yield)\b/g,string:/@?("|')(\\?.)*?\1/g,preprocessor:/^\s*#.*/gm,number:/\b-?(0x)?\d*\.?\d+\b/g});; +/** + * My own languages + */ +Prism.languages.befunge = {};; + (function(){if(!self.Prism){return}var e={csharp:"C#",cpp:"C++"};Prism.hooks.add("before-highlight",function(t){var n=e[t.language]||t.language;t.element.setAttribute("data-language",n)})})(); diff --git a/www/protected/config/main.php b/www/protected/config/main.php index a99839c..653c91c 100644 --- a/www/protected/config/main.php +++ b/www/protected/config/main.php @@ -81,6 +81,14 @@ return ArrayX::merge( 'update' => 'api/update', 'update/' => 'api/update2', + 'blog/' => 'blogPost/index', + 'blog/ajaxMarkdownPreview' => 'blogPost/ajaxMarkdownPreview', + 'blog/admin' => 'blogPost/admin', + 'blog/create' => 'blogPost/create', + 'blog/index' => 'blogPost/index', + 'blog/update' => 'blogPost/update', + 'blog/' => 'blogPost/view/id/', + 'downloads/details.php' => 'programs/index', // Compatibility 'downloads/downloads.php' => 'programs/index', // Compatibility 'downloads/' => 'programs/view', // Compatibility diff --git a/www/protected/controllers/BlogPostController.php b/www/protected/controllers/BlogPostController.php new file mode 100644 index 0000000..72ce5f9 --- /dev/null +++ b/www/protected/controllers/BlogPostController.php @@ -0,0 +1,191 @@ +array('index','view', 'ajaxMarkdownPreview'), + 'users'=>array('*'), + ), + array('allow', // allow authenticated user to perform 'create' and 'update' actions + 'actions'=>array('create','update','admin','delete'), + 'users'=>array('@'), + ), +// array('allow', // allow admin user to perform 'admin' and 'delete' actions +// 'actions'=>array(), +// 'users'=>array('admin'), +// ), + array('deny', // deny everythign else to all users + 'users'=>array('*'), + ), + ); + } + + /** + * Displays a particular model. + * @param integer $id the ID of the model to be displayed + */ + public function actionView($id) + { + $this->render('view',array( + 'model'=>$this->loadModel($id), + )); + } + + /** + * Creates a new model. + * If creation is successful, the browser will be redirected to the 'view' page. + */ + public function actionCreate() + { + $this->layout = '//layouts/column2'; + + $model=new BlogPost; + + // Uncomment the following line if AJAX validation is needed + // $this->performAjaxValidation($model); + + if (isset($_POST['BlogPost'])) { + $model->attributes=$_POST['BlogPost']; + if ($model->save()) { + $this->redirect(array('view','id'=>$model->ID)); + } + } + + $this->render('create',array( + 'model'=>$model, + )); + } + + /** + * Updates a particular model. + * If update is successful, the browser will be redirected to the 'view' page. + * @param integer $id the ID of the model to be updated + */ + public function actionUpdate($id) + { + $this->layout = '//layouts/column2'; + + $model=$this->loadModel($id); + + // Uncomment the following line if AJAX validation is needed + // $this->performAjaxValidation($model); + + if (isset($_POST['BlogPost'])) { + $model->attributes=$_POST['BlogPost']; + if ($model->save()) { + $this->redirect(array('view','id'=>$model->ID)); + } + } + + $this->render('update',array( + 'model'=>$model, + )); + } + + /** + * Deletes a particular model. + * If deletion is successful, the browser will be redirected to the 'admin' page. + * @param integer $id the ID of the model to be deleted + * @throws CHttpException + */ + public function actionDelete($id) + { + $this->layout = '//layouts/column2'; + + $this->loadModel($id)->delete(); + + // if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser + if (!isset($_GET['ajax'])) { + $this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('admin')); + } + } + + /** + * Lists all models. + */ + public function actionIndex() + { + $dataProvider=new CActiveDataProvider('BlogPost'); + $this->render('index',array( + 'dataProvider'=>$dataProvider, + )); + } + + public function actionAjaxMarkdownPreview() { + if(Yii::app()->request->isAjaxRequest){ + $this->renderPartial('_ajaxMarkdownPreview', + [ + 'Content' => $_POST['Content'], + ], + false, true); + } else { + throw new CHttpException(400,'Invalid request. This is a Ajax only action.'); + } + } + + /** + * Manages all models. + */ + public function actionAdmin() + { + $this->layout = '//layouts/column2'; + + $model=new BlogPost('search'); + $model->unsetAttributes(); // clear any default values + if (isset($_GET['BlogPost'])) { + $model->attributes=$_GET['BlogPost']; + } + + $this->render('admin',array( + 'model'=>$model, + )); + } + + /** + * Returns the data model based on the primary key given in the GET variable. + * If the data model is not found, an HTTP exception will be raised. + * @param integer $id the ID of the model to be loaded + * @return BlogPost the loaded model + * @throws CHttpException + */ + public function loadModel($id) + { + $model=BlogPost::model()->findByPk($id); + if ($model===null) { + throw new CHttpException(404,'The requested page does not exist.'); + } + return $model; + } + + /** + * Performs the AJAX validation. + * @param BlogPost $model the model to be validated + */ + protected function performAjaxValidation($model) + { + if (isset($_POST['ajax']) && $_POST['ajax']==='blog-post-form') { + echo CActiveForm::validate($model); + Yii::app()->end(); + } + } +} \ No newline at end of file diff --git a/www/protected/models/BlogPost.php b/www/protected/models/BlogPost.php new file mode 100644 index 0000000..42afb43 --- /dev/null +++ b/www/protected/models/BlogPost.php @@ -0,0 +1,99 @@ +'search'), + ); + } + + /** + * @return array relational rules. + */ + public function relations() + { + // NOTE: you may need to adjust the relation name and the related + // class name for the relations automatically generated below. + return array( + ); + } + + /** + * @return array customized attribute labels (name=>label) + */ + public function attributeLabels() + { + return array( + 'ID' => 'ID', + 'Date' => 'Date', + 'Title' => 'Title', + 'Content' => 'Content', + ); + } + + /** + * Retrieves a list of models based on the current search/filter conditions. + * + * Typical usecase: + * - Initialize the model fields with values from filter form. + * - Execute this method to get CActiveDataProvider instance which will filter + * models according to data in model fields. + * - Pass data provider to CGridView, CListView or any similar widget. + * + * @return CActiveDataProvider the data provider that can return the models + * based on the search/filter conditions. + */ + public function search() + { + // @todo Please modify the following code to remove attributes that should not be searched. + + $criteria=new CDbCriteria; + + $criteria->compare('ID',$this->ID); + $criteria->compare('Date',$this->Date,true); + $criteria->compare('Title',$this->Title,true); + $criteria->compare('Content',$this->Content,true); + + return new CActiveDataProvider($this, array( + 'criteria'=>$criteria, + )); + } + + /** + * Returns the static model of the specified AR class. + * Please note that you should have this exact method in all your CActiveRecord descendants! + * @param string $className active record class name. + * @return BlogPost the static model class + */ + public static function model($className=__CLASS__) + { + return parent::model($className); + } +} diff --git a/www/protected/views/blogPost/_ajaxMarkdownPreview.php b/www/protected/views/blogPost/_ajaxMarkdownPreview.php new file mode 100644 index 0000000..44b06c4 --- /dev/null +++ b/www/protected/views/blogPost/_ajaxMarkdownPreview.php @@ -0,0 +1,3 @@ + + +
+ + beginWidget('bootstrap.widgets.TbActiveForm', array( + 'id'=>'blog-post-form', + // Please note: When you enable ajax validation, make sure the corresponding + // controller action is handling ajax validation correctly. + // There is a call to performAjaxValidation() commented in generated controller code. + // See class documentation of CActiveForm for details on this. + 'enableAjaxValidation'=>false, +)); ?> + +

Fields with * are required.

+ + errorSummary($model); ?> + + textFieldControlGroup($model,'Date',array('span'=>5)); ?> + + textFieldControlGroup($model,'Title',array('span'=>8)); ?> + + textAreaControlGroup($model,'Content',array('rows'=>30,'span'=>8)); ?> + + 'POST', + 'data' => ['Content' => 'js: $("#BlogPost_Content").val()'], + 'update' => '#markdownAjaxContent', + 'error'=>'function(msg){alert("An error has happened" + JSON.stringify(msg));}', + ]); ?> + +
+
+ +
+ renderPartial('_ajaxMarkdownPreview', ['Content' => $model->Content, ], false, true); ?> +
+ +
+ isNewRecord ? 'Create' : 'Save',array( + 'color'=>TbHtml::BUTTON_COLOR_PRIMARY, + 'size'=>TbHtml::BUTTON_SIZE_LARGE, + )); ?> +
+ + endWidget(); ?> + +
\ No newline at end of file diff --git a/www/protected/views/blogPost/_search.php b/www/protected/views/blogPost/_search.php new file mode 100644 index 0000000..e4119e3 --- /dev/null +++ b/www/protected/views/blogPost/_search.php @@ -0,0 +1,26 @@ + + +
+ + beginWidget('bootstrap.widgets.TbActiveForm', array( + 'action'=>Yii::app()->createUrl($this->route), + 'method'=>'get', +)); ?> + + textFieldControlGroup($model,'ID',array('span'=>5)); ?> + + textFieldControlGroup($model,'Date',array('span'=>5)); ?> + + textAreaControlGroup($model,'Content',array('rows'=>6,'span'=>8)); ?> + +
+ TbHtml::BUTTON_COLOR_PRIMARY,));?> +
+ + endWidget(); ?> + +
\ No newline at end of file diff --git a/www/protected/views/blogPost/_view.php b/www/protected/views/blogPost/_view.php new file mode 100644 index 0000000..c6f5d75 --- /dev/null +++ b/www/protected/views/blogPost/_view.php @@ -0,0 +1,25 @@ + + +
+ + getAttributeLabel('ID')); ?>: + ID),array('view','id'=>$data->ID)); ?> +
+ + getAttributeLabel('Date')); ?>: + Date); ?> +
+ + getAttributeLabel('Title')); ?>: + Title); ?> +
+ + getAttributeLabel('Content')); ?>: + Content); ?> +
+ + +
\ No newline at end of file diff --git a/www/protected/views/blogPost/admin.php b/www/protected/views/blogPost/admin.php new file mode 100644 index 0000000..27bcd32 --- /dev/null +++ b/www/protected/views/blogPost/admin.php @@ -0,0 +1,57 @@ +breadcrumbs=array( + 'Blog Posts'=>array('index'), + 'Manage', +); + +$this->menu=array( + array('label'=>'List BlogPost', 'url'=>array('index')), + array('label'=>'Create BlogPost', 'url'=>array('create')), +); + +Yii::app()->clientScript->registerScript('search', " +$('.search-button').click(function(){ + $('.search-form').toggle(); + return false; +}); +$('.search-form form').submit(function(){ + $('#blog-post-grid').yiiGridView('update', { + data: $(this).serialize() + }); + return false; +}); +"); +?> + +

Manage Blog Posts

+ +

+ You may optionally enter a comparison operator (<, <=, >, >=, + <> +or =) at the beginning of each of your search values to specify how the comparison should be done. +

+ +'search-button btn')); ?> + + +widget('bootstrap.widgets.TbGridView',array( + 'id'=>'blog-post-grid', + 'dataProvider'=>$model->search(), + 'filter'=>$model, + 'columns'=>array( + 'ID', + 'Date', + 'Content', + array( + 'class'=>'bootstrap.widgets.TbButtonColumn', + ), + ), +)); ?> \ No newline at end of file diff --git a/www/protected/views/blogPost/create.php b/www/protected/views/blogPost/create.php new file mode 100644 index 0000000..5120efa --- /dev/null +++ b/www/protected/views/blogPost/create.php @@ -0,0 +1,20 @@ + + +breadcrumbs=array( + 'Blog Posts'=>array('index'), + 'Create', +); + +$this->menu=array( + array('label'=>'List BlogPost', 'url'=>array('index')), + array('label'=>'Manage BlogPost', 'url'=>array('admin')), +); +?> + +

Create BlogPost

+ +renderPartial('_form', array('model'=>$model)); ?> \ No newline at end of file diff --git a/www/protected/views/blogPost/index.php b/www/protected/views/blogPost/index.php new file mode 100644 index 0000000..cda5315 --- /dev/null +++ b/www/protected/views/blogPost/index.php @@ -0,0 +1,23 @@ + + +pageTitle = 'Blog - ' . Yii::app()->name; + +$this->breadcrumbs = array( + 'Blog' => array('/blog'), +); + +$this->selectedNav = 'blog'; + +?> + +

Blog Posts

+ +widget('bootstrap.widgets.TbListView',array( + 'dataProvider'=>$dataProvider, + 'itemView'=>'_view', +)); ?> \ No newline at end of file diff --git a/www/protected/views/blogPost/update.php b/www/protected/views/blogPost/update.php new file mode 100644 index 0000000..955e2b5 --- /dev/null +++ b/www/protected/views/blogPost/update.php @@ -0,0 +1,26 @@ + + +pageTitle = 'Update Blogpost - ' . Yii::app()->name; + +$this->breadcrumbs = array( + 'BlogPosts' => array('index'), + $model->Title => array('/blog/view/' . $model->ID), + 'Update', +); + +$this->menu=array( + array('label'=>'List BlogPost', 'url'=>array('index')), + array('label'=>'Create BlogPost', 'url'=>array('create')), + array('label'=>'View BlogPost', 'url'=>array('view', 'id'=>$model->ID)), + array('label'=>'Manage BlogPost', 'url'=>array('admin')), +); +?> + +

Update BlogPost ID; ?>

+ +renderPartial('_form', array('model'=>$model)); ?> \ No newline at end of file diff --git a/www/protected/views/blogPost/view.php b/www/protected/views/blogPost/view.php new file mode 100644 index 0000000..7abeafd --- /dev/null +++ b/www/protected/views/blogPost/view.php @@ -0,0 +1,24 @@ + + +pageTitle = 'Blogpost: ' . $model->Title . ' - ' . Yii::app()->name; + +$this->breadcrumbs = array( + 'Blog' => array('/blog'), + $model->Title, +); +?> + +
+ +

View BlogPost #ID; ?>

+ +
+ Content); ?> +
+ +
diff --git a/www/protected/views/layouts/main.php b/www/protected/views/layouts/main.php index 9fee382..c71948a 100644 --- a/www/protected/views/layouts/main.php +++ b/www/protected/views/layouts/main.php @@ -51,8 +51,8 @@ 'items' => [ ['label' => 'Home', 'url' => '/', 'active' => ($this->selectedNav === 'index')], - ['label' => 'Blog', 'url' => '#', 'active' => ($this->selectedNav === 'blog')], - ['label' => 'Programs', 'url' => '/programs/', 'active' => ($this->selectedNav === 'prog')], + ['label' => 'Blog', 'url' => '/blog', 'active' => ($this->selectedNav === 'blog')], + ['label' => 'Programs', 'url' => '/programs', 'active' => ($this->selectedNav === 'prog')], ['label' => '', 'items' => ProgramHelper::GetProgDropDownList(), 'htmlOptions' => ['class' => 'dropdown-append']], ['label' => 'About', 'url' => '/about', 'active' => ($this->selectedNav === 'about')], ['label' => '[[Log "' . Yii::app()->user->name . '" out]]', 'url' => '/logout', 'visible' => !Yii::app()->user->isGuest, 'htmlOptions' => ['class' => 'cstm-main-navbar-highlight']] diff --git a/www/protected/views/log/_form.php b/www/protected/views/log/_form.php index be6a5d2..2ad1df2 100644 --- a/www/protected/views/log/_form.php +++ b/www/protected/views/log/_form.php @@ -35,7 +35,7 @@ 'type'=>'POST', 'data' => ['content'=> 'js: $("#Log_content").val()'], 'update' => '#markdownAjaxContent', - 'error'=>'function(msg){alert("An error has happened");}', + 'error'=>'function(msg){alert("An error has happened" + JSON.stringify(msg));}', ]); ?>
diff --git a/www/protected/views/programs/admin.php b/www/protected/views/programs/admin.php index a07efbf..e604da3 100644 --- a/www/protected/views/programs/admin.php +++ b/www/protected/views/programs/admin.php @@ -9,11 +9,6 @@ $this->breadcrumbs=array( 'Manage', ); -$this->menu=array( - array('label'=>'List Program', 'url'=>array('index')), - array('label'=>'Create Program', 'url'=>array('create')), -); - Yii::app()->clientScript->registerScript('search', " $('.search-button').click(function(){ $('.search-form').toggle(); diff --git a/www/protected/views/programs/index.php b/www/protected/views/programs/index.php index 31bd69f..566a17a 100644 --- a/www/protected/views/programs/index.php +++ b/www/protected/views/programs/index.php @@ -14,6 +14,9 @@ $this->pageTitle = 'Programs - ' . Yii::app()->name; $this->breadcrumbs = array( 'Programs', ); + +$this->selectedNav = 'prog'; + ?>