MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn moreOpportunities for recent engineering grads.

Apply TodaySearch Solutions

What is Size?

Size refers to the number of nodes in a parse tree. Generally speaking, you can think of size as code length.

234Size

0 Comments

234Size

0 Comments

Incorrect

0 Comments

251Size

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

67Size

0 Comments

Incorrect

0 Comments

90Size

0 Comments

68Size

3 Comments

3 Comments

Jan Orwat
on 17 Sep 2014

Sorry for resubmitting an old regexp solution. Seems, that previous one disappeared. I have to solve this problem the proper way.

Paul Berglund
on 18 Sep 2014

I think that this solution is perfectly legitimate. Why try to solve it "properly"? It's not like you are using eval or something like that. regexprep is a perfectly legitimate tool to use.

Jan Orwat
on 18 Sep 2014

I agree with your point of view. Regexprep is a powerful function here.
Unfortunately I've used also '(??@some_code)'. In this case, it's not as bad as playing 'size=11' solution, but it is still a kind of size-cheating for me. I used to play solutions like that, but now I try to avoid this.

138Size

1 Comment

1 Comment

Jon
on 17 Sep 2014

At the time of submission, all better scores use either a lookup table or regexp.

169Size

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

283Size

0 Comments

281Size

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

227Size

0 Comments

289Size

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

263Size

0 Comments

Incorrect

0 Comments

228Size

0 Comments

Incorrect

0 Comments

283Size

0 Comments

211Size

0 Comments

140Size

0 Comments

144Size

0 Comments

Incorrect

0 Comments

217Size

0 Comments

218Size

0 Comments

Incorrect

0 Comments

325Size

0 Comments

398Size

0 Comments

362Size

0 Comments

Incorrect

0 Comments

Incorrect

0 Comments

235Size

0 Comments

Incorrect

0 Comments

250Size

0 Comments

305Size

0 Comments

314Size

0 Comments

250Size

0 Comments

235Size

0 Comments

264Size

0 Comments

264Size

0 Comments

Incorrect

0 Comments