Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Challenges

Post History

50%
+0 −0
Challenges Getting perfect squares, differently

Lua, 41 40 bytes x=0 y=1while""do print(x)x=x+y y=y+2 end Try it online!

posted 3y ago by General Sebast1an‭  ·  edited 3y ago by General Sebast1an‭

Answer
#2: Post edited by user avatar General Sebast1an‭ · 2021-09-11T00:14:15Z (over 3 years ago)
  • # [Lua], 41 bytes
  • <!-- language-all: lang-lua -->
  • x=0 y=1 while""do print(x)x=x+y y=y+2 end
  • [Try it online!][TIO-ktb6mm2g]
  • [Lua]: https://www.lua.org/
  • [TIO-ktb6mm2g]: https://tio.run/##yylN/P@/wtZAodLWUKE8IzMnVUkpJV@hoCgzr0SjQrPCtkK7EihXqW2kkJqX8v@/oQEA "Lua – Try It Online"
  • # [Lua], <s>41</s> 40 bytes
  • <!-- language-all: lang-lua -->
  • x=0 y=1while""do print(x)x=x+y y=y+2 end
  • [Try it online!][TIO-ktf1cgcj]
  • [Lua]: https://www.lua.org/
  • [TIO-ktf1cgcj]: https://tio.run/##yylN/P@/wtZAodLWsDwjMydVSSklX6GgKDOvRKNCs8K2QrsSKFWpbaSQmpfy/7@hAQA "Lua – Try It Online"
#1: Initial revision by user avatar General Sebast1an‭ · 2021-09-08T07:30:45Z (over 3 years ago)
# [Lua], 41 bytes

<!-- language-all: lang-lua -->

    x=0 y=1 while""do print(x)x=x+y y=y+2 end

[Try it online!][TIO-ktb6mm2g]

[Lua]: https://www.lua.org/
[TIO-ktb6mm2g]: https://tio.run/##yylN/P@/wtZAodLWUKE8IzMnVUkpJV@hoCgzr0SjQrPCtkK7EihXqW2kkJqX8v@/oQEA "Lua – Try It Online"