I've been hanging around on Code Golf Stack Exchange a lot, posting often in TI-BASIC, which is surprisingly good at code golf in simple math challenges and such. However, something that TI-BASIC isn't good at is string manipulation. Empty strings error when you try to do anything with them, inString( and sub( are clunky and slow, etc. But they can be interesting to optimize for size.

Therefore, I have posted a massive 600-point bounty on this challenge to see who can best optimize TI-BASIC string manipulation programs. To put that in perspective, 600 reputation points typically takes me about three weeks of constant posting to earn.

To submit your answer, make a SE account if you don't already have one, and post it in spoilers as an answer to the question. If you have the smallest sum of sizes of your solutions to the twelve challenges, I'll award you 200 (in 3 days) and then another 400 if you're still winning in 10 days.[/url]
This certainly seems interesting. I'll take a crack at it. I'll ask questions when I have them.
lirtosiast wrote:
I've been hanging around on Code Golf Stack Exchange a lot, posting often in TI-BASIC, which is surprisingly good at code golf in simple math challenges and such. However, something that TI-BASIC isn't good at is string manipulation. Empty strings error when you try to do anything with them, inString( and sub( are clunky and slow, etc. But they can be interesting to optimize for size.

Therefore, I have posted a massive 600-point bounty on this challenge to see who can best optimize TI-BASIC string manipulation programs. To put that in perspective, 600 reputation points typically takes me about three weeks of constant posting to earn.

To submit your answer, make a SE account if you don't already have one, and post it in spoilers as an answer to the question. If you have the smallest sum of sizes of your solutions to the twelve challenges, I'll award you 200 (in 3 days) and then another 400 if you're still winning in 10 days.[/url]

my my, those all seem like very interesting things to try out, however, I strongly doubt you could get more than like 3 done in 140 bytes... I might give some of them a try... is hybrid-basic allowed? Not sure if I could make good use of it, but MAYBE since there are some string manipulation commands in there...
Hybrid BASIC is not allowed.

The challenge is not how many you can get done in 140 bytes, but how small you can get the solutions to all 12 sub-challenges, so golf away.
For the ASCII clock input...how are we actually doing that?
mr womp womp wrote:
my my, those all seem like very interesting things to try out, however, I strongly doubt you could get more than like 3 done in 140 bytes... I might give some of them a try... is hybrid-basic allowed? Not sure if I could make good use of it, but MAYBE since there are some string manipulation commands in there...

I created a working one with 134 bytes, so it is always possible.
In the ASCII clock input challenge, you may assume the string input contains a newline character 0x3F, although there's no way to actually type one in.

(I'll need to clear that with the challenge's OP but I think it'll be fine.)

@PT_: Which challenge is your 134-byte solution for?

Just a heads up: the first bounty ends tomorrow.
lirtosiast wrote:
In the ASCII clock input challenge, you may assume the string input contains a newline character 0x3F, although there's no way to actually type one in.

(I'll need to clear that with the challenge's OP but I think it'll be fine.)

@PT_: Which challenge is your 134-byte solution for?

Just a heads up: the first bounty ends tomorrow.

Well, I thought you would type it in with the characters of line one, enough spaces to bring the cursor to the next line, rinse and repeat for the entire image. Is that a way to do it?
lirtosiast wrote:
@PT_: Which challenge is your 134-byte solution for?
The third one, with the keyboard stuff.
JWinslow23 wrote:

Well, I thought you would type it in with the characters of line one, enough spaces to bring the cursor to the next line, rinse and repeat for the entire image. Is that a way to do it?


No, because the string to process would be different. You can see that the strings in the challenge page don't have trailing spaces on each line, and that there's a newline character after each line.
PT_ wrote:
lirtosiast wrote:
@PT_: Which challenge is your 134-byte solution for?
The third one, with the keyboard stuff.

I have 96 bytes for that same problem. I used a For( loop with inString to change the cursor. In order, for each problem I have done so far (up to the Square Clock, for which I am still confused), I have 22, (not done, oh no), 96, 69, 61, 67, and 61 bytes. Which means if I were competing, I could fit a whopping TWO tasks in a tweet! Razz

For now, I'm just gonna say the "new line" character is any other character, it doesn't matter what it is.
What I have so far, in order:
19 Smile, (not done), 134, 45, 59, 64, 49, 67, but I need to change the last one.

EDIT: with the first task, is a list as input also good? Then I have 17 bytes.
Yes, a list is valid input. Remember also that the program header doesn't count for the size.
Oh no. I left my calculator at my cousin's house, and the bounty ends tomorrow Sad
How do you propose we attack Perimiterize and Prime Tweet in this language? Also, the program size is the byte count given in the memory menu, minus the name length, minus 8. Is this correct? (Edit: Changed from 9 to 8; I guess we're stuck with the initial newline.)
I'm sorry to hear that, JWinslow23; you can still compete for next week's 400 rep though.

Wow, Weregoose is competing. I'm honored.

Standard PCG practice is to not count the leading newline; for Perimiterize you may take input either as:

* a string containing newline characters (0x3F) or

* multiple lines of Input, then a closing delimeter on the line after the last. For example to input


Code:
XXX.
X...


you enter at the ? prompts


Code:
?XXX.
?X...
??


In Prime Tweet you should output a string with every printable ASCII character, not necessarily the tokens. So you can use *row( for *, r, o, and w.

EDIT: Changed rules based on asking OP; sorry
Posting here because not enough reputation points.

In Task 2, getting over that jacobly typed an extra closing parenthesis in line four, the fixed program fails to meet all but one of the test cases given in the assignment (it doesn't appear to inspect numbers smaller than 10^6 as possibly being closer). This was the program's working state at the time the bounty was awarded (his last edit was six hours prior).

He absolutely did some great things there, though. In all honesty, I think it's fair to give him the win.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement