Languages have their purposes
Page 1 of 112 Replies - 3858 Views - Last Post: 26 June 2011 - 04:33 PM
#1
Languages have their purposes
Posted 24 June 2011 - 11:09 PM
Php is great for web developement, f# is (from what I've heard) good for math stuff; etc.
What's your language and what's the best use of it?
Replies To: Languages have their purposes
#2
Re: Languages have their purposes
Posted 25 June 2011 - 12:00 AM
#3
Re: Languages have their purposes
Posted 25 June 2011 - 01:06 AM
My favorite language is (obviously) Clojure. It's pretty difficult to choose a 'best' use for it, but if I had to, it would probably be concurrent applications. Clojure is designed from the ground up to make concurrency easy and boasts an STM (software transactional memory) system.
This post has been edited by Raynes: 25 June 2011 - 11:32 AM
#4
Re: Languages have their purposes
Posted 25 June 2011 - 05:24 AM
There are some places you have to go "bare metal" and run on the machine, here C++ and C are the most popular choices. For everything else, it's an interpretor / virtual machine. Within the VM sandbox, depending on how sandboxed they are, most general purpose languages hold there own.
I'm a professional developer in Windows, so in that domain it's C# all the way. In Windows, you don't really get to play with the hardware; everything is abstracted through the OS. So, for most practical purposes, the CLR of .NET is not much of an impediment.
For all else, I prefer Python. A clean, multi-paradigm language, that let's you go as shallow or deep as you like with your prefered solution. You can write a simple sequential program or an OO beast. You can be draconian about typing if you have to, but you really don't have to. While interpreted, it semi compiles and usually hooks into C for the heaving lifting.
I just read an interesting article about Basic, with Python as the star, chosen over Java: Basic is (mostly) dead. Long live Python as the next starter language?
Though I admit to enjoying the simplicity of C at times and will go C++ for amusement.
#5
Re: Languages have their purposes
Posted 25 June 2011 - 02:58 PM
I do have some problems with Python as a starting language - I'd prefer C, or Java in a pinch. Basically, I want the student to have to work a bit at understanding the fundamentals, and Python doesn't really give you that. I know, Spolsky already wrote that article, but I think he's got a lot of good points there, and they apply as much to the shift from Java to Python as they do for the shift from C to Java - in both cases you're coddling the students' self esteem instead of demanding that they actually work at understanding what's going on.
If you go through Sedgewick's Algorithms text in C, you can be pretty sure you understand what's going on down to the bare metal. If you do the same in Python, I'm not sure you get the same benefit.
This post has been edited by jon.kiparsky: 25 June 2011 - 03:04 PM
#6
Re: Languages have their purposes
Posted 25 June 2011 - 05:26 PM
Quote
maybe, i will have to see how big Basic. there may be a very simple dialect that would be fit for use in a challenge here on DIC.
i use C++ and Lua for almost everything. in fact i like using Lua so much that often times i will simply expose a C++ library to Lua(just the parts that i need typically) and write the whole application in Lua. as for the benefits of C++...well it's nutso fast and i have been using it for 2 years now so im pretty adept at using. as for Lua it would have to be the single most extensible/embeddable language there is Lua is also fast, garbage collected, and dynamically typed which makes it very simple to use.
This post has been edited by ishkabible: 25 June 2011 - 05:27 PM
#7
Re: Languages have their purposes
Posted 25 June 2011 - 06:43 PM
jon.kiparsky, on 25 June 2011 - 05:58 PM, said:
Heh, I know what you mean. I fired up some GW-BASIC (gotta love DosBox) for one of DIC's coding challenges a while back. The nostalgia was so heavy it was painful. However, I was struck that an old line BASIC programmer would have a pretty good handle on assembly flow. Also, how short the list of commands is. I did think about implementing an interpretor at that time.
jon.kiparsky, on 25 June 2011 - 05:58 PM, said:
I really can't say for sure what I think the best starting language is. Modern languages have tons of built in goodies. You can look at that and say it's good, because the student can concentrate on fundamental concepts, or it's bad because everything already has a class or library waiting to go.
I've recommended Java as a first language, based on it's draconian OO model and strong typing, which I feel are core concepts. But I'm not sure. From that place, I can see how python my be more appealing.
I also see the plain old C side. It teaches all the basics of a procedural language, the idea of data types ( if not strictly enforced ), and a more fundamental understanding of how computers actually think. While it's gotchas are straight forward, they also tend to just blow up rather that giving a good reason, which may be a problem.
Honestly, there's nothing quite like old line BASIC. There are so many languages, but nothing quite there.
#8
Re: Languages have their purposes
Posted 25 June 2011 - 07:38 PM
here is a list that i think is pretty well rounded
C/C++ -- lower level procedural programing, this acts as a kinds of bridge between Java and assembly
Java -- teaches pure OO, strong typing, and very structured programing
assembly -- doesn't matter what architecture. just so long as you have the ultra low level
Lua -- any scripting language will do, i just like Lua
Haskell -- purely functional, this forces you to think functioanly and solve problems diffrently
Lisp -- again, this is employs different techniques even from Haskell. i think this is a nice addtion to the list
these are all very cross platform languages as well, C# would probably teach the same things as Java. F# could teach what lisp and Haskell teach. i just prefer cross-platform languages generally speaking.
This post has been edited by ishkabible: 25 June 2011 - 07:45 PM
#9
Re: Languages have their purposes
Posted 25 June 2011 - 07:53 PM
ishkabible, on 25 June 2011 - 10:38 PM, said:
Not saying it isn't. The question on the table, however, was which to begin with.
For the record, my first programming language was good old fashioned BASIC. First on a VIC 20, but it wasn't mine. Apple ][ ( yeah, they spelled it like that ), and ultimately the first computer of my very own; an Atari 800.
Lua is interesting. I feels it's quite similar to Javascript, actually. Python or Ruby will scratch the same itch. I go with Python here because it's has to most tools to recommend it. If I needed an embedded language, Lua of course wins.
#10
Re: Languages have their purposes
Posted 26 June 2011 - 06:57 AM
Quote
Ah the good old days!
This was actually my second language, the VIC was the first computer I purchased, no hard drive (had a cassette tape) and the small amount of memory really made for "creative" coding to get most anything of any use to run.
For my first language I started with dBase II using a Kaypro running on the CP/M operating system, no hard disks, just 2 5-1/2 floppies.
Jim
This post has been edited by jimblumberg: 26 June 2011 - 06:58 AM
#11
Re: Languages have their purposes
Posted 26 June 2011 - 09:25 AM
My roots are C/Assembly. Nothing like full control!...when you have the time.
#12
Re: Languages have their purposes
Posted 26 June 2011 - 12:03 PM
#13
Re: Languages have their purposes
Posted 26 June 2011 - 04:33 PM
it's a language of a rather large complexity. it may be smaller than C++ but it's still a rather obtuse language. Java is not so obtuse if you ask me. also D isn't that much faster either, i was kinda disappointed to find that out
if you ask me how D could have been better then i give you this
*take C as a base, eliminate ambiguous definitions like int* x;, take a Go route here
*make arrays like Java arrays, such that all are dynamically allocated and garbage collected
*make pointers only allow pointing to single objects and make them garbage collected
*take away some of the unnecessary syntax of C
*add simple OO mechanisms
you have your self a clean, future proof, language that should be simple, fast, and garbage collected
as an added bonus you may want to add the advanced array features of D, concatenation, slicing, ect...
This post has been edited by ishkabible: 26 June 2011 - 04:36 PM
|
|

New Topic/Question
Reply




MultiQuote











|