Talk:Rockstar

From Esolang
Jump to navigation Jump to search

Code example: code points to string

(Rockstar program that converts a space-separated list of Unicode code points into their string representation then prints it.)
(Redefine your_heart to change the base of the code points.)
(I suggest "Your heart is a poison." for base 16)
(and "Your heart is a powerhouse." for base 10.)

Your love's got me. It's making me crazy. (your_love = 32 point whatever, doesn't matter)
Turn it down. (rounds down to 32, ASCII value of space)
Burn it. (your_love = charFromCode⟨your_love⟩, i.e. space)
Your heart is a poison. (your_heart = the base for casting)

Listen to your dreams. (store input into your_dreams)
Cut it into memories with your love. (memories = split⟨your_dreams, delimiter=your_love⟩)
The end is inevitable. (the_end = 0)
Love is contentment. (love = 1)
Rock the truth. (the_truth = [])

While the end is weaker than memories, (while the_end < len⟨memories⟩:)
Let me be memories at the end. (me = memories[the_end])
Burn me into your eyes with your heart. (your_eyes = string⟨me, base=your_heart⟩)
Burn your eyes into me. (me = charFromCode⟨your_eyes⟩)
Rock the truth with me. (the_truth.push⟨me⟩)
Let the end be with love (the_end = the_end + love)
(Blank line that breaks the While loop)
Unite the truth. (the_truth = join⟨the_truth, ""⟩)
Shout it. (print the_truth)

HaleyHalcyon (talk) 14:23, 4 June 2022 (UTC)