<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.minetest.org/index.php?action=history&amp;feed=atom&amp;title=User%3AHajo%2Ftest1</id>
	<title>User:Hajo/test1 - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.minetest.org/index.php?action=history&amp;feed=atom&amp;title=User%3AHajo%2Ftest1"/>
	<link rel="alternate" type="text/html" href="https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;action=history"/>
	<updated>2026-07-21T08:27:24Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.3</generator>
	<entry>
		<id>https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=13082&amp;oldid=prev</id>
		<title>&gt;Hajo: /* Lua */ &lt;source lang=&quot;lua&quot;&gt;</title>
		<link rel="alternate" type="text/html" href="https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=13082&amp;oldid=prev"/>
		<updated>2017-03-11T04:52:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Lua: &lt;/span&gt; &amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 21:52, 10 March 2017&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>&gt;Hajo</name></author>
	</entry>
	<entry>
		<id>https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=9317&amp;oldid=prev</id>
		<title>&gt;Hajo: /* Lua */ &lt;source lang=&quot;lua&quot;&gt;</title>
		<link rel="alternate" type="text/html" href="https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=9317&amp;oldid=prev"/>
		<updated>2017-03-11T04:52:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Lua: &lt;/span&gt; &amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 21:52, 10 March 2017&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>&gt;Hajo</name></author>
	</entry>
	<entry>
		<id>https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=5552&amp;oldid=prev</id>
		<title>&gt;Hajo: /* Lua */ &lt;source lang=&quot;lua&quot;&gt;</title>
		<link rel="alternate" type="text/html" href="https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=5552&amp;oldid=prev"/>
		<updated>2017-03-11T04:52:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Lua: &lt;/span&gt; &amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 21:52, 10 March 2017&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>&gt;Hajo</name></author>
	</entry>
	<entry>
		<id>https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=1787&amp;oldid=prev</id>
		<title>&gt;Hajo: /* Lua */ &lt;source lang=&quot;lua&quot;&gt;</title>
		<link rel="alternate" type="text/html" href="https://wiki.minetest.org/index.php?title=User:Hajo/test1&amp;diff=1787&amp;oldid=prev"/>
		<updated>2017-03-11T04:52:21Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Lua: &lt;/span&gt; &amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;==Table-test==&lt;br /&gt;
&lt;br /&gt;
===10x10===&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! __ !! AA !! BB !! CC !! DD !! EE !! FF !! GG !! HH !! II !! JJ&lt;br /&gt;
|-&lt;br /&gt;
| :: || a1 || b1 || c1 || d1 || e1 || f1 || g1 || h1 || i1 || j1&lt;br /&gt;
|-&lt;br /&gt;
| :: || a2 || b2 || c2 || d2 || e2 || f2 || g2 || h2 || i2 || j2&lt;br /&gt;
|-&lt;br /&gt;
| :: || a3 || b3 || c3 || d3 || e3 || f3 || g3 || h3 || i3 || j3&lt;br /&gt;
|-&lt;br /&gt;
| :: || d4 || d1 || d1 || d1 || d1 || d1 || d1 || d1 || d1 || d4&lt;br /&gt;
|-&lt;br /&gt;
| :: || e5 || e1 || e1 || e1 || e1 || e1 || e1 || e1 || e1 || e5&lt;br /&gt;
|-&lt;br /&gt;
| :: || f6 || f1 || f1 || f1 || f1 || f1 || f1 || f1 || f1 || f6&lt;br /&gt;
|-&lt;br /&gt;
| :: || g7 || g1 || g1 || g1 || g1 || g1 || g1 || g1 || g1 || g7&lt;br /&gt;
|-&lt;br /&gt;
| :: || h8 || h1 || h1 || h1 || h1 || h1 || h1 || h1 || h1 || h8&lt;br /&gt;
|-&lt;br /&gt;
| :: || i9 || i1 || i1 || i1 || i1 || i1 || i1 || i1 || i1 || i9&lt;br /&gt;
|-&lt;br /&gt;
| :: || j0 || j1 || j1 || j1 || j1 || j1 || j1 || j1 || j1 || j0&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
===Lua - Online-IDEs===&lt;br /&gt;
* https://www.lua.org/cgi-bin/demo&lt;br /&gt;
* http://ideone.com/&lt;br /&gt;
&lt;br /&gt;
Example - Formatting a table:&lt;br /&gt;
&lt;br /&gt;
====Prog1====&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
 for y = -200, 200, 20 do&lt;br /&gt;
  for x = -200, 200, 20 do&lt;br /&gt;
    print(x,y)&lt;br /&gt;
  end&lt;br /&gt;
 end&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Prog2====&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
 n1,n2,step=-200, 200, 50&lt;br /&gt;
 n1,n2,step=-150, 150, 50&lt;br /&gt;
 print(&amp;quot;===Table===&amp;quot;)&lt;br /&gt;
 for y = n1,n2,step do&lt;br /&gt;
  --print(y..&amp;quot;: &amp;quot;)&lt;br /&gt;
  s=string.format(&amp;quot;y=%4d : &amp;quot;,y)&lt;br /&gt;
  for x = n1,n2,step do&lt;br /&gt;
   s = s..string.format(&amp;quot;%4d,%4d &amp;quot;, x,y)&lt;br /&gt;
   --print(x,y)&lt;br /&gt;
  end&lt;br /&gt;
  print(s); s=&amp;quot;&amp;quot;&lt;br /&gt;
 end&lt;br /&gt;
 print(&amp;quot;--&amp;quot;)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Output=====&lt;br /&gt;
 ===Table===&lt;br /&gt;
 y=-150 : -150,-150 -100,-150  -50,-150    0,-150   50,-150  100,-150  150,-150 &lt;br /&gt;
 y=-100 : -150,-100 -100,-100  -50,-100    0,-100   50,-100  100,-100  150,-100 &lt;br /&gt;
 y= -50 : -150, -50 -100, -50  -50, -50    0, -50   50, -50  100, -50  150, -50 &lt;br /&gt;
 y=   0 : -150,   0 -100,   0  -50,   0    0,   0   50,   0  100,   0  150,   0 &lt;br /&gt;
 y=  50 : -150,  50 -100,  50  -50,  50    0,  50   50,  50  100,  50  150,  50 &lt;br /&gt;
 y= 100 : -150, 100 -100, 100  -50, 100    0, 100   50, 100  100, 100  150, 100 &lt;br /&gt;
 y= 150 : -150, 150 -100, 150  -50, 150    0, 150   50, 150  100, 150  150, 150 &lt;br /&gt;
 --&lt;br /&gt;
&lt;br /&gt;
====Prog3====&lt;br /&gt;
Task:&lt;br /&gt;
formatting a table for the wiki&lt;br /&gt;
&lt;br /&gt;
====Wiki-Table====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Y \ X          !! x=-100 !! x=-50 !! x=0 !! X=50 !! x=100&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;y=-150&amp;#039;&amp;#039;&amp;#039; : || -100,-150 || -50,-150 || 0,-150 || 50,-150 || 100,-150&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;y=   0&amp;#039;&amp;#039;&amp;#039; : || -100, 0   || -50, 0   || 0, 0 || +50, 0 || 100, 0&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;y= 150&amp;#039;&amp;#039;&amp;#039; : || -100, 150 || -50, 150 || 0, 150 || +50, 150 || +100, 150&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
====Code====&lt;br /&gt;
&amp;lt;source lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
--n1,n2,step=-200, 200, 50&lt;br /&gt;
  n1,n2,step=-150, 150, 50&lt;br /&gt;
  print(&amp;#039;{| class=&amp;quot;wikitable&amp;quot;&amp;#039;)&lt;br /&gt;
  --&lt;br /&gt;
  print(&amp;#039;|-\n! X,Y !! ...&amp;#039;)&lt;br /&gt;
  --&lt;br /&gt;
  for y = n1,n2,step do&lt;br /&gt;
   s=string.format(&amp;quot;|-\n| y=%4d : &amp;quot;,y)&lt;br /&gt;
   for x = n1,n2,step do&lt;br /&gt;
    s = s..string.format(&amp;quot;|| %4d,%4d &amp;quot;, x,y)&lt;br /&gt;
   end&lt;br /&gt;
   print(s); s=&amp;quot;&amp;quot;&lt;br /&gt;
  end&lt;br /&gt;
  print(&amp;quot;|}&amp;quot;)&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Output=====&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! X,Y !! ...&lt;br /&gt;
|-&lt;br /&gt;
| y=-150 : || -150,-150 || -100,-150 ||  -50,-150 ||    0,-150 ||   50,-150 ||  100,-150 ||  150,-150 &lt;br /&gt;
|-&lt;br /&gt;
| y=-100 : || -150,-100 || -100,-100 ||  -50,-100 ||    0,-100 ||   50,-100 ||  100,-100 ||  150,-100 &lt;br /&gt;
|-&lt;br /&gt;
| y= -50 : || -150, -50 || -100, -50 ||  -50, -50 ||    0, -50 ||   50, -50 ||  100, -50 ||  150, -50 &lt;br /&gt;
|-&lt;br /&gt;
| y=   0 : || -150,   0 || -100,   0 ||  -50,   0 ||    0,   0 ||   50,   0 ||  100,   0 ||  150,   0 &lt;br /&gt;
|-&lt;br /&gt;
| y=  50 : || -150,  50 || -100,  50 ||  -50,  50 ||    0,  50 ||   50,  50 ||  100,  50 ||  150,  50 &lt;br /&gt;
|-&lt;br /&gt;
| y= 100 : || -150, 100 || -100, 100 ||  -50, 100 ||    0, 100 ||   50, 100 ||  100, 100 ||  150, 100 &lt;br /&gt;
|-&lt;br /&gt;
| y= 150 : || -150, 150 || -100, 150 ||  -50, 150 ||    0, 150 ||   50, 150 ||  100, 150 ||  150, 150 &lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>&gt;Hajo</name></author>
	</entry>
</feed>