HNHacker News
TopNewBestAskShowJobs

kung-fu-master

445 karma · joined October 18, 2010

submissionscomments
kung-fu-master··on Go 1.2
From this message I understood that the Go is a language only for him and not for others developers.
kung-fu-master··on Ask HN: Best Python web framework
Flask is best IMHO. Django is good enough.
kung-fu-master··on JavaScript at Khan Academy
Ok, maybe Java on some cases worse choice over JS. But Java has one preeminence over JS. With Java we can teach more advantage level of software construction. It's construction of medium/large systems. Programming in big. Using classical OOP, interfaces and specification in achieving modularity and decoupling.

JS was built for small scripts on web pages.

I think Python is a worse choice because it's also more complicated and less elegant than JavaScript (and it has its own share of pitfalls), but that seems to be a minority opinion around here.

You wrong, Python is much elegant than JS. Starting from syntax which was derived from C/C++ like languages. With a lot of bugs and confusing behaviors (some of was mentioned by Resig itself).

Code in Python is very clear and looks like pseudo-code. It's very easy to read and very easy to start writing in it.

JS - specialized language for Web. Python - general purpose language.

Prototypal inheritance is much simpler than classical inheritance--you don't even have to introduce the idea of a class. I think it would be easier to teach prototypal inheritance rather than classical inheritance to people with no programming experience.

There should be no inheritance for beginners. It's not even core CS concept. No classes, no OOP in any kind of it (prototypal, classical).

I think with this approach we will get not CS professionals. We will get JS script kiddies.

kung-fu-master··on JavaScript at Khan Academy
As CS teacher I'm agree with others that JS is terrible choice as first language. Python is much better. Also Pascal is good option here. Even Java better than JS.

What is their goal. It seems that John Resig only wants to teach his favorite language/tool JS.

Main goal must be to teach fundamental CS concepts, programming basics, algorithms and data structures. Language choice is must to be appropriate to that goals.

He talks about teaching prototypal inheritance, is he serious? For those how have not any prior programming experience.

It seems, that he has no any prior pedagogical experience. Why that guy make such decisions and why Khan academy can't hire more experienced CS teacher.

Yes, I know, he is great guy who wrotes jQuery, but pedagogy and JS programming is two very different areas.

kung-fu-master··on Linus Torvalds on C++
But Mercurial was written in Python and performance is comparable to git. So, his argument is not correct about the performance reason on choice of C over C++. Even interpreted Python which was used in Mercurial was not speed bottleneck. Yes, I know that most of speed critical sections was written in C. But almost all project in Python.

Also Darcs was written in Haskell and Bazaar with Python.

I hate C++ too (over 10 years of experience). But Linus is full of BS too.

Yes, choice of C language in Git is right choice. But source code of Git is horrible and unmaintainable mess.

kung-fu-master··on Lisp: It's Not About Macros, It's About Read
Have you looked at Nemerle?
kung-fu-master··on Ask HN: Best Intro Programming Book?
Why not HTDP or SICP?
kung-fu-master··on Ask HN: How should programming be taught at university?
As school teacher I think that "Introduction to programming" should increase motivation on further learning of programming.

About 10-20 years ago it was very simple task. Computers and programming were very exciting.

What has changed? Nowadays there are a lot of interesting and distracting factors like computer games, TV, Internet etc.

I think our primary goal is to make learning computer science more interesting and fun. It must be more interesting than computer games and TV. It is really interesting than computer games! We just need to show that for our students.

How can we do that? For example, at our school I have made 3D robots simulator which has own simple programming language. Students are programming virtual robot to reach some goals. It's like game. Also I have made "real" robot based on Arduino with IR sensors.

As a result I can see increased interest and motivation of my students.

kung-fu-master··on Fun environment for hobby 3D game?
Try Panda3D (www.panda3d.org)
kung-fu-master··on Ask HN: How many hours do you spend coding per day?
From 2 to 4 hours. Everyday.
kung-fu-master··on Ask HN: Silence in Lisp community
I have found 31 repos on Common Lisp. Clojure - 3956 repos.

Compare to: Ruby - 141811 repos. Python - 67482 repos.

It seems that writing on Ruby is more fun than writing in Lisp.

kung-fu-master··on Nemerle 1.0
Exactly. AFAIK, it has small core language and all other constructions like if/else, while, for, foreach etc are made with macros.

I think that Nemerle is Lisp macros + static types + OCaml (algebraic data types, pattern matching) + .Net ecosystem (even Visual Studio support).

kung-fu-master··on Ela Programming Language
http://www.haskell.org/haskellwiki/GHC:FAQ#Why_isn.27t_GHC_a...
kung-fu-master··on Ela Programming Language
There is article about language but it's only in russian: http://rsdn.ru/article/dotnet/ElaDevelopment.xml

I will ask author to translate it into english.

kung-fu-master··on Ask PG: Lisp vs Python (2010)
Hmmm... it's interesting...

I came to conclusion that it is easier to do external DSL, not embedded. Parse source code on Pascal and then translate it into S-expressions. Am I right?

Btw, if I'm gonna write external DSL, I can do that in any language for example on Python. So, what's the difference?

kung-fu-master··on Ask PG: Lisp vs Python (2010)
There are such DSLs on top of Common Lisp. But usually not on the scope of a full programming language like Pascal. It is not that typical anymore, but there are examples in that direction.

---------------------------

I have found two examples:

1. Python in Lisp: http://github.com/franzinc/cl-python

2. Ruby on Lisp: http://jng.imagine27.com/articles/2010-10-07-084756_ruby_sub...

I will try to write little subset of Pascal as eDSL on Lisp.

kung-fu-master··on Ask PG: Lisp vs Python (2010)
Then, why no one still not made such eDSL? As I understand, the only reason to choose Python for Peter Norvig was the similarity of Python to pseudo-code. I think that such great hacker as Peter Norvig could easily develop pseudo-code eDSL on top of Lisp macro-system.

As school teacher on programming I'm limited in choice of programming languages. The only language which I can study is Pascal (a lot of other reasons on it). The problem is that Pascal have not any libraries (GUI, 2D/3D, Game Development Engines, programming micro-controllers, ...). Students can write only simple console applications. So, it was be ideal to have subset of Pascal as eDSL on top of Common Lisp or Clojure. In that way I can easily extend original Pascal to access some real world libraries.

I think also on top of Common Lisp we can develop some simpler eDSL as pseudo-code for beginner students.

PS: gone to learn Common Lisp...

kung-fu-master··on Ask PG: Lisp vs Python (2010)
I'm not a Lisp expert, so I have another question. Is it possible to embed DSL into Lisp which will looks like pseudo-code?

For example:

(pseudo

    a = 0

    b = 100

    s = 0

    for (i from a to b)

        s = s + i

    write(s)
)

If such pseudo code can be embedded into SBCL it would generate fast machine code, also it would be possible to easily modify pseudo code syntax.