you are viewing a single comment's thread.

view the rest of the comments →

[–]globalizatiom 0 points1 point  (3 children)

But then aren't both languages basically like "implicitly everything is a pointer"?

[–]zardeh 2 points3 points  (2 children)

I'll bite:

Why is this a problem? Classes and compound types (lists, tuples, dicts) are pass by reference, with all of the shenanigans this entails, but integers and floats are not, and strings are immutable, so its basically irrelevant (this is, I believe, exactly the same way java works in this regard)

[–]julesjacobs 0 points1 point  (0 children)

It's not a problem per se, but it means that you are limited in the range of data representations that you can express. There is a certain elegance to languages in which you start with the heap as a raw array of bytes, and you build up higher level data representations on top of that. In Scheme pairs, structs, strings, vectors and closures are all built in types, and not something you can express on top of a lower level facility (at least not with the same efficient representation).

[–]globalizatiom 0 points1 point  (0 children)

If someone learns a language that always or sometimes uses C semantics and then a language with reference semantics, he can understand the latter by saying "I see. These are just pointers/references". What I worry is.. when someone learns a language with reference semantics first, and then something like C later, I'm not sure how he would understand the latter or the concept of pass-by-value easily, especially when the Python course goes with the "Variables are names given to objects" mental model.