TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

I told my 2nd year CS students to create a programming language [RESULTS]

17 pointsby dovyskiabout 13 years ago

4 comments

Udoabout 13 years ago
This is a very cool experiment, this should be standard practice in teaching CS. I'm a little surprised at the limitations of their interpreters, given the fact that they are 2nd year already - but then again, they were given the task do develop a language for a very specific test case.<p>The absence of support for nested loop/if constructs probably means they didn't write parsers that generate trees, but rather chose to execute scripts line-by-line, right?<p>I'd like to ask you fellow hackers: if you created a toy programming language today, what features would it have?
评论 #3974041 未加载
laserDinosaurabout 13 years ago
Ok, I'll be the slow witted one in the room - When creating your own language, what did you write it in? If you're using Java or C, are you still using it's compiler but coming up with your own syntax? I'm a little confused how it worked.
评论 #3975737 未加载
jhrobertabout 13 years ago
There exists tons of "toy" language implementation available online. I wonder why no students came up with a forth or lisp like solution that would have been able to handle nested loops, ifs, etc...<p>When I was in my 2nd year as a CS student, one of the assignment was to reimplement the Unix's M4 preprocessor (a superset of C's preprocessor), based on its manual... It includes an expression evaluator, we were told that tools like lex and yacc would help...<p>Well... that was 25 years ago.
评论 #3976047 未加载
kodablahabout 13 years ago
"I think it happened because they wrote just C code until now (they will meet PHP next semester)."<p>This surprises me. Of the higher-level languages you (or your school) could choose, why PHP? I understand for beginners, but why for students coming from a C background?
评论 #3974071 未加载
评论 #3973654 未加载