Posted: Fri Feb 20, 2009 1:20 pm Post subject: RE:Collections (real collections!) in Turing
OpenT is toast as far as I know. Their domain isn't registered. If they were still alive, I'd be implementing some kind of syntax to use these natively in Turing.
If you have any suggestions as to what you'd like to see added to this (assuming you're still coding in Turing...), feel free. If anyone who's actually learning in Turing is using these / becomes capable of using these before they graduate to another language, let me know what you think (please!).
What I'd do to Turing syntax:
1. Allow forward class declarations.
2. Allow cheat to be used on pointers. Better yet, replace cheat with some kind of operator like so:
code:
var specificVar : ^Specific := cast baseVar to ^Specific
3. Allow variable-length arrays to be passed as a result from functions. This would permit the toArray() function from the Java API, however useless it may be.
4. Replace Turing's current new syntax with the C++/Java syntax: Object myObj = new Object()
4.1. As the previous point implies, constructors would now be optional, and would have the same name as their class.
5. Lists/sets/maps/queues would be easy:
code:
var myList : list of {type}
where type is any primitive, record or object. This includes the following:
code:
var playerProfiles : map of ( string, list of ^Profile )
which would of course be a map from Turing's string primitive to a list of Profile objects (presumably multiple profiles indexed by player name).
6. Allow Turing keywords to be used as object names, particularly the IO functions (put, get, read, write). So when you say:
code:
class SomeClass
export put
proc put ()
% Output code here
end put
end SomeClass
var instance : ^SomeClass := new SomeClass()
put instance
it would, instead of saying "invalid put object", execute the class in the put method (and if you specified a stream in your put command, it would route output from the put() method to that stream automagically. This would be like Java's toString() or C++ operator-overloading, except limited to the put, get, read, write operations.
7. Allow overloading based on parameter list type. This is the standard in Java/C++/probably lots of other languages, and it's a whole lot nicer than separate method names for everything.
8. At the very least, add an instanceof operator, if not access to the className of a given object.
Sponsor Sponsor
SNIPERDUDE
Posted: Fri Feb 20, 2009 1:49 pm Post subject: RE:Collections (real collections!) in Turing
So do you think Holtsoft is actually going to produce the open-source code they've been promising?
EDIT:
Hmm, turns out they don't even have their website up anymore...
DemonWasp
Posted: Fri Feb 20, 2009 2:49 pm Post subject: RE:Collections (real collections!) in Turing
Yup, Holtsoft is well and truly dead. I would assume that this means no open-source code (they may have looked at it and gone "oh gods, we can't release this").
If students are lucky, this means that schools in Ontario will end up switching to another language. I would assume VB would be the likely candidate (C++ is harsh, Java is too complex for a newcomer, most other languages aren't likely to be considered by the schoolboard...). If the students are really lucky, they'll switch to another language; maybe Python, which I've heard is easy to learn.
What's more likely is that schools will stick with an increasingly-outdated Turing as the inertia to change is high. Sadly, OpenT could have stepped in here and made life a lot better for students, but no such luck.
P.S. If anyone on the original OpenT team can point me to how to set up / build / run the original OpenT code (their GoogleCode SVN is still up), I'd be much obliged.
saltpro15
Posted: Fri Feb 20, 2009 3:30 pm Post subject: RE:Collections (real collections!) in Turing
oh lord no not basic, basic should be killed with fire. hopefully c++ but I know the intellectual capacity of the gr9 and 10's coming into CS in the next few years that unless some brain transplants occur, there's a better chance of water catching on fire.
DemonWasp
Posted: Fri Feb 20, 2009 4:08 pm Post subject: RE:Collections (real collections!) in Turing
It's really not the fault of the students. C++ is a complicated, difficult language. There are hundreds of hidden complications that stem from issues a beginner cannot understand (generally, they can't even understand the reason for the complication immediately - I know I frequently couldn't). Even in a year-long course at that level, I would have had a hard time picking up C++ (point of reference, I taught myself enough Java to "get by" that year of CS).
Normally I would agree that BASIC is an awful language. It is! But VB .NET improves a few things (or so I've heard, latest version of VB I've used was 6, and it lacked proper OOP capabilities among other issues), and really it's the only option for a real GUI in a high-school-level program. Theoretically, you could do so with C++ or Java or whatever else, it's just easiest (and the most immediate response) in VB.
In all honesty, schools should probably be looking at Pascal (which is what was generally used before Turing, as I recall, hence Holtsoft compared their performance in teaching to Pascal's) and Python. Ideally, it'd be a language that abstracts you away from the minutiae of the machine enough that newcomers can get comfortable writing small, useful applications before they get into the heavier stuff.
copthesaint
Posted: Fri Feb 20, 2009 9:36 pm Post subject: RE:Collections (real collections!) in Turing
Actually word is that That they are switching to Ruby. Now this as I was told is not a 'For sure thing' but yea that's what I've heard, and I know for sure that they are using a new language at the end of the year. Well this is for The best, Maybe.
The reason why I've heard is because I'm still in grade 10 and Btw I'm teaching myself java and I am still at the basic hence, I haven't posted any programs in java.
Also just a question off topic did you figure out how to make a custom text field? couldn't figure it out.
SNIPERDUDE
Posted: Sun Feb 22, 2009 6:52 pm Post subject: RE:Collections (real collections!) in Turing
I'd agree with Python as the next. Just an opinion.
darkangel
Posted: Sun Feb 22, 2009 11:55 pm Post subject: Re: Collections (real collections!) in Turing
I have to admit, Python is an amazing Language. It took me less than an hour and I had written my first program. It was a web spider that went to each of my favorite websites and downloaded any new content into a folder. So I wouldn't have to go looking for it.
As long as they teach Python 3K and not the 2.X. 3K is more like other languages thus decreasing the time it would take for a new student to switch out of Python and into another language.
Also, hated VB with a firery passion. PHP made my life as a Web Application Programmer soooo much easier. After all, nothing can beat it's documentation
(ex php.net/commandNameHere)
Sponsor Sponsor
Analysis Mode
Posted: Mon Mar 23, 2009 11:51 pm Post subject: Re: RE:Collections (real collections!) in Turing
Turing is, according to my CS teacher, a rip-off of C++ and Pascal that some guy made just so he could earn money (and he did, just look at how many schools in Ontario use Turing). But I have to emphasize the fact that in most CS competitions and online judges (SPOJ, USACO Training Pages / contests), Turing is not an admissible language (apart from CCC Stage 1 and ECOO). In fact, I doubt anyone outside of an Ontario high school uses Turing. Also, Turing is quite slow, I hear. In Gr 10 at our school, Pascal is taught. It is a simple, powerful language and anyone staring at a Pascal program can kind of figure out what it's doing. C++, which I use, is an even more powerful language but yes, it is more difficult to learn, as random things DO happen.
DemonWasp
Posted: Tue Mar 24, 2009 1:44 am Post subject: RE:Collections (real collections!) in Turing
Turing seems to be a combination of C (in most regards, including its tremendous inability to do any high-level work) and bits of Pascal. We can thank whatever dieties we believe in that they realised how bad the C++ OO-system was and decided to avoid it. For most of the stuff you see students doing in Turing, you can convert line-for-line into C code.
Turing is slow; at an estimate, it's about 1% of the speed of compiled C++ for most operations, though even that may be generous. It's not the slowest language out there (most Javascript implementations being much slower), but it's also not fast. OpenT would have fixed that (it'd be nearly Java-speed, which is essentially C++-speed).
Python is probably a better first choice; it avoids the nonsense of the machine / OS / hardware but lets the programmer touch on the high-level concepts. It also forces proper indentation, which makes it a lot easier to read code (and therefore, learn how to code).
C++ is, in my opinion, not a terribly great language. It was a good first try, but let's take the lessons-learned from that fiasco and put them to use in our latest set of languages and forget the hulking beast as soon as possible. You might be able to tell that I'm not enjoying the work-in-C++ aspect of my job right now; this is because it won't just BUILD ALREADY.
Warchamp7
Posted: Tue Mar 24, 2009 8:21 am Post subject: RE:Collections (real collections!) in Turing
It's a real shame OpenT died off. It looked promising.