User:RikoMamaBala
Jump to navigation
Jump to search
I do all sorts of programming stuff, from Scratch, to Python, to even a custom-made machine code that can actually be interpreted(no, really)!
My interests in Scratch
I do all fancy stuff in Scratch. From:
when green flag clicked
forever
move 10 steps
turn CW 15 degrees
Up to the levels where I am cookig and proving that Scratch is Turing-complete:
when green flag clicked setup ask(BrainF code:) and wait compress compile run
define setup: erase all delete all of memory delete all of output add ' ' to output set g to 0 set /ptr to 1
You get the idea.
Some things that I do in Python
But I don't only do Scratch. I also tinker around with Python, which is kinda same to Scratch, so here is a Beatnik to score points reader in Python that I made.
alphabet = ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "w", "x", "y", "z"]
score = [1, 3, 3, 2, 1, 4, 2, 4, 1, 8, 5, 1, 3, 1, 1, 3, 10, 1, 1, 1, 1, 4, 4, 8, 4, 10]
print("Word to Beatnik code")
text = input()
words = []
terminal = []
word = ""
for i in range(len(text)):
if text[i] == " ":
words.append(word)
word = " "
word = word + text[i]
words.append(word)
for i in range(len(words)):
scorepoint = 0
for dontcare in range(len(word)):
try:
scorepoint += score[alphabet.index(words[i][dontcare])]
except:
try:
scorepoint += score[alphabet.index(words.lower()[i][dontcare])]
except:
scorepoint = scorepoint
terminal.append(scorepoint)
print(terminal)
Pretty cool, right?
Some things I'm planning
I plan to do some Esolang interpreters(like Brainfuck, Thue, Befunge, etc...)and put them on this studio. Feel free to add your own esolangs and/or interpreters!
I don't know what to say anymore
If you want to view the code that outputs the text of this article, then go here.