Why is writing C so hard!

Hey, y'all.

A friend of mine was really into Pascal and wrote a 3D rendering engine using that. He was able to embed Assembler into his Pascal code. Now, I'm not sure all Pascal compilers (interpreters??) allow this, but the one he was using obviously did. Just thought I'd mention this in response to something someone posted where they were asking whether you could do this ... ramble, ramble ...

Also - MacOS was programmed in Pascal? That explains a thing or two :)

Another point I'd like to reiterate is that no language makes for bad programming or good programming. You can find good, clean, readable C source, just as you can find really ugly, unreadable Java code (I have to help out newbies at work, and the things they can do with Java even Satan would have difficulty dreaming up :))
That's one of the problems I find with many "learn to program in X" courses - they teach the syntax, but forget to teach you about programming.

Also, I agree that one should definitely differentiate between C and C++/ObjectiveC, etc. C is one thing, and the rest is ... well ... something else, really.

Oh, and Java is based partly on C++ (also on Smalltalk) ... and C++ is based on C ... so Java kind of has bits of C in it. Mainly syntaxy stuff. And of course they went to great lengths to avoid all the "nasty" (i.e. somewhat awkward) stuff from C/C++ ... like pointers (I once had the nickname Pointer Bender, coz I could do things with pointers not even the computer was quite sure of, hehehe :)).

Anyway - if your looking for a "nice syntax" language, take a look at Python. Personally, I like it -- took a bit of getting used to, but one of the main goals (I believe) was to create a language with a clean syntax.

Sorry for rambling on a bit.

Cheers,

C
 
That's one of the problems I find with many "learn to program in X" courses - they teach the syntax, but forget to teach you about programming.
Those books aren't meant to teach the skills of programming, they're meant to teach the syntax of the language.

If you need an explanation of a for loop, the "Teach yourself {language} in X days" isn't a good choice. But if you don't know how to write a for loop in Java (or Perl, or C, or whatever) but already know what a for loop is, they work fine.

Python == ick ;)

But I ranted about Python already (in this thread) so I'll leave it alone.

Edit: Correct spelling and add link to the thread o' Python rant
 
I said courses. I checked. Says so right there in my post! :)
Wasn't talking about books. Wasn't criticising books. I was talking about courses. Ah well. Lesen muss gelernt sein :)

C
 
... and I won't post a huge rave about Python, coz I know its good and in the end its down to taste. Just thought someone should mention it here in context with clean syntax. My advice - check it out - if you don't like (which you obviously don't nkuvu, then go with something else :) Personally, I like it, and as far as scripting languages go, its the one I choose every time (apart from real simple small stuff where I stick with Bash/sed/awk).

:)

C
 
... I agree with the point nkuvu was making:

Once you actually *have* learned how to program, then a good reference book can be very handy. Of course, in these days of always on, broadband internet I find it easier going to one of my fave sites ... or in the case of some v. well documented languages (Java, Python) the online docs are mostly more than enough :)

C
 
I want to put together a unix embedded OS that can be used for digtal sound . I want to design my own effects gear beeing a guitar maker and an enthusiast . I have been talking about this for years , I want to have something together by the fall .
 
Originally posted by LordCoven
I said courses. I checked. Says so right there in my post! :)
Wasn't talking about books. Wasn't criticising books. I was talking about courses. Ah well. Lesen muss gelernt sein :)

C
Man, that's twice I misread a post. Sorry, won't happen again. :eek:

which you obviously don't nkuvu, then go with something else
Which is what I am doing. ;) Just wanted to express my opinion of the matter, nothing more.

the online docs are mostly more than enough
The only time I buy hardcopy text is for 1. Something I know I'll use a lot, like Perl, 2. Something that has poor to no online documentation, like DXL (a scripting language for a program called Doors), or 3. A good reference for something I know but keep forgetting the syntax (because I'm switching languages too often) like C/C++. I keep trying to make foreach loops in C... :rolleyes:

p.s. LordCoven, what does "Lesen muss gelernt sein" mean? The fish says "Vintages must be learned" :confused:
 
Lesen = read. reading must be learned (by tortoise).

i wonder what that nonsense about embedded UNIX for guitars was all about...
 
nkuvu - to your point 1) why you buy hardcopy. I find it interesting that you buy hardcopy for something that you use a lot, coz its exactly the opposite for me. The two languages I use most are Java and Python (both professionally and 'at home') and although I did buy hardcopy when I was learning, I haven't looked at those books since that time (quite a while ago now for both). But then I'm not switching languages as much (pretty much sticking with Java/Python) so perhaps that's why.
The reason I like hardcopy is so that I can learn a language on the move. OK, its not quite as necessary since I got my iBook ;), but I still like books for that, coz you can sit out in the park and read them on a sunny day, which is a trifle tricky with an LCD/TFT monitor. BTW: I learned Python by downloading the tutorial as HTML onto my iPaq and reading it while on the loo ... hehehe. Truly mobile :) (hope I didn't put anyone off their food just then :))

PS: Lesen muss gelernt sein (as was pointed out by the last poster) means 'The ability to read must be learned' - its something I say to myself a lot when I make a stupid mistake with syntax or typo in a method name or the like when programming. :)

Right, I'll stop rambling now.

Cheers,

C
 
Originally posted by 96.9
I want to put together a unix embedded OS that can be used for digtal sound . I want to design my own effects gear beeing a guitar maker and an enthusiast . I have been talking about this for years , I want to have something together by the fall .

Sweet! I assume you'd be starting from a pre-existing OS; no point building your own when free stuff exists...

Keep us posted
 
Ya , the companies like Roland have thier own OS they use . I will be building off an existing open source embedded OS .

I have lots of stuff to research , but I will get back to ya'll in a few days . I have been sort of waiting for the open source embedded scene to get rolling , there is some nice stuff on the market in the software and hardware department . The embedded field has been a great employer in todays slow market if you have the connections .

I just think it would be fun for people to just download something to setup in your own rig .
 
Back
Top