Wanting Advice Please... - Slackware

This is a discussion on Wanting Advice Please... - Slackware ; Joost Kremers wrote: > Blazar Jet wrote: >> I would like to learn how to program. >> Where should I start? > the choice of language really depends on what you want to do. python is > useless if you ...

+ Reply to Thread
Page 2 of 3 FirstFirst 1 2 3 LastLast
Results 21 to 40 of 49

Thread: Wanting Advice Please...

  1. Re: Wanting Advice Please...

    Joost Kremers wrote:

    > Blazar Jet wrote:
    >> I would like to learn how to program.
    >> Where should I start?


    > the choice of language really depends on what you want to do. python is
    > useless if you want to program kernel drivers, for instance. OTOH if you
    > want to write higher-level programs that interact with the user through a
    > GUI, something like python might be a better idea, as it'll get you
    > results quicker than a language like C or C++.


    My fault - I should have included more information into my initial post.

    I am nearing retiement after 30 years in comp tech hardware and would like
    to learn programming "best prectices' with the thought of perhaps helping
    out with some F/OSS projects. Perhaps starting by cleaning up code and
    writing docs.

    The thought also occurs to me that some projects are sitting dormant and it
    might be helpful to try and bring them back to life.

    I have been using Linux since 1995 and would love to contribute back in the
    next 30 years of my life. (I am confined to a wheelchair now)

    > if you just want to get an idea of what programming is like, and see what
    > you can do with it, i'd suggest python. results are quick, it's useful for
    > scripts to automate all sorts of file maintenance tasks, it's not too
    > difficult to write GUI programs with it, and it'll scale up to larger
    > programs as well.


    > then if you later decide you want to program specific things, you can
    > always switch to another language more suited to those tasks.


    Thanks for your input.

    BJ


  2. Re: Wanting Advice Please...

    On Tue, 22 Jan 2008 15:46:27 +0000, Blazar Jet wrote:

    > You recommend starting with C++ and then I should be able to understand
    > C.


    Not really, the common idioms are very different. Although you can write
    pure C in C++, it does seem pointless.

    Nonetheless, if you want to do systems programming, C ROOLZ!

    > I am going to try and understand the Zen of 'procedural vs object
    > oriened'.


    Programming isn't about a particular language. It's a way of thinking.
    Or collection of ways. Mostly the languages get in the way of the
    thinking by making you focus on the distractions.

    The best way to learn is with something modern and working at a high
    abstraction level, like Ruby.

    Not many programming books are as well written as Why's (Poignant) Guide
    to Ruby:

    http://poignantguide.net/

    As a benefit, if you ever decide to commercialise your programming
    skillz, Ruby on Rails coders are in high demand :-)

  3. Re: Wanting Advice Please...

    Tom N wrote:
    > On 2008-01-22, Blazar Jet wrote:
    >> I would like to learn how to program.
    >>
    >> Where should I start?

    >
    > Bash then C.


    I totally agree. Bash is probably the easiest way to learn what
    programming is about. You'll be able to write simple, useful scripts
    after a few days of learning on your own.

    --
    Wallman
    http://www.3dwallpaper.ws ::: 3D wallpapers :::

  4. Re: Wanting Advice Please...

    Blazar Jet writes:

    > Loki Harfagr wrote:
    >
    >> Tue, 22 Jan 2008 07:44:25 +0000, Blazar Jet did cat*:
    >>> I would like to learn how to program.

    >
    >> Fine, but what do you want to program for?

    >
    > I am nearing retirement and have been involved on the hardware side of comp
    > tech for close to 30 years and now wish to actually learn the basics of
    > writing clean fat appropriately commendted code.



    Well, I'm not a programmer, just a dabbler! But I have found these
    books (versions of the same book) rather useful



    http://www.openbookproject.net/thinkCS/

    How to Think Like a Computer Scientist

    Python | Java | Logo | C++

    These texts are introductions to Computer Science in an increasing number
    of both programming languages and natural languages. The order of
    presentation is what might be called "procedural first," which means that
    the programming style is mostly procedural until the later chapters,
    which introduce object-oriented programming.

    They are intended for people with little or no programming experience,
    and are appropriate for first year college or advanced high school
    students, or anyone interested in learning to program. All versions are
    under the GNU Free Documentation License.


    Just about my level!! Might be a good place to start.

    atb


    Glyn
    --
    RTFM http://www.tldp.org/index.html
    GAFC http://slackbook.org/ The Official Source :-)
    STFW http://groups.google.com/groups?hl=e...inux.slackware
    JFGI http://jfgi.us/

  5. Re: Wanting Advice Please...

    Blazar Jet wrote:
    >I actually passed a couple courses in assembly language in the DOS
    >environment 25 years ago.


    That's excellent... C is just one nice step up from assembly, and it's
    nice to be able to have an idea of what assembly the compiler is
    producing.

    In school, I watched people struggle with learning assembly language
    after learning the patterns of a high-level language, but people who had
    learned assembly first had little trouble with it even when it was new
    to them. It seemed like the order in which the patterns were learned
    was important.

    A general knowledge of assembly language has been useful in virtually
    every job I've had, whether I was working on Windows, PalmOS, or the
    Playstation2, even if I was rarely writing code in it.

    >I really loved it but was overwwhelmed by the bewildering array of DOS
    >calls.


    One of the hardest things of learning any new language isn't the syntax;
    it's learning the huge number of calls at your disposal.

    Take C# vs Java, for instance. The languages are very similar, but they
    both have gigantic support libraries. If you know Java, you'll have a
    good idea of what you can do in C#, but you'll have to spend time
    looking it all up.

    >I am nearing retirement and looking to increase my understanding. Who
    >knows, maybe write the Great American Program.


    Laudable goals!

    -Beej


  6. Re: Wanting Advice Please...

    Beej Jorgensen wrote:

    > Blazar Jet wrote:
    >>I actually passed a couple courses in assembly language in the DOS
    >>environment 25 years ago.


    > That's excellent... C is just one nice step up from assembly, and it's
    > nice to be able to have an idea of what assembly the compiler is
    > producing.


    > In school, I watched people struggle with learning assembly language
    > after learning the patterns of a high-level language, but people who had
    > learned assembly first had little trouble with it even when it was new
    > to them. It seemed like the order in which the patterns were learned
    > was important.


    > A general knowledge of assembly language has been useful in virtually
    > every job I've had, whether I was working on Windows, PalmOS, or the
    > Playstation2, even if I was rarely writing code in it.


    That is good information!

    I think I should revisit my understanding of assembler again - it's been a
    long time since I have written anything beyond a VERY simple printer
    driver.

    >>I really loved it but was overwwhelmed by the bewildering array of DOS
    >>calls.


    > One of the hardest things of learning any new language isn't the syntax;
    > it's learning the huge number of calls at your disposal.


    Ok.

    > Take C# vs Java, for instance. The languages are very similar, but they
    > both have gigantic support libraries. If you know Java, you'll have a
    > good idea of what you can do in C#, but you'll have to spend time
    > looking it all up.


    Ok. Is most of this online or am I going to be buying a lot of books?

    >>I am nearing retirement and looking to increase my understanding. Who
    >>knows, maybe write the Great American Program.


    > Laudable goals!


    Thanks - it would be nice to be able to contribute something back.

    BJ


  7. Re: Wanting Advice Please...

    Blazar Jet wrote:
    >I wish I understood the relationship between C and C++ - that may help me
    >make an informed decision.


    It's a different programming paradigm; that's the biggest thing, IMO.
    C++ started as "C with Classes", which was a way of bringing
    object-oriented programming to the procedural world of C.

    Here's a great list: http://en.wikipedia.org/wiki/Programming_paradigm

    In it you'll find Procedural Programming (C) and Object-oriented
    Programming (C++). C++ can also behave almost entirely like C, but
    that's not its /raison d'etre/.

    Both can solve the same problems, but they're sort of different ways of
    thinking about them.

    For me personally, and this is not an exhaustive list by any means, the
    biggest winners for using C++ (or some OO language) over C are games and
    user interfaces. These are both applications where you have definite
    "things that do stuff" (windows, widgets, or game entities), so it's
    good to have an OO language that naturally describes "things that do
    stuff". If you have a list of things to do, (i.e. a procedure you have
    to go through) then a procedural programming language could be better.
    (This is much more of a guideline than a rule.)

    Python and C++ are OO/procedural hybrids, and can be programmed either
    way.

    -Beej


  8. Re: Wanting Advice Please...

    Beej Jorgensen wrote:

    > Blazar Jet wrote:
    >>I wish I understood the relationship between C and C++ - that may help me
    >>make an informed decision.


    > It's a different programming paradigm; that's the biggest thing, IMO.
    > C++ started as "C with Classes", which was a way of bringing
    > object-oriented programming to the procedural world of C.


    > Here's a great list: http://en.wikipedia.org/wiki/Programming_paradigm


    > In it you'll find Procedural Programming (C) and Object-oriented
    > Programming (C++). C++ can also behave almost entirely like C, but
    > that's not its /raison d'etre/.


    > Both can solve the same problems, but they're sort of different ways of
    > thinking about them.


    > For me personally, and this is not an exhaustive list by any means, the
    > biggest winners for using C++ (or some OO language) over C are games and
    > user interfaces. These are both applications where you have definite
    > "things that do stuff" (windows, widgets, or game entities), so it's
    > good to have an OO language that naturally describes "things that do
    > stuff". If you have a list of things to do, (i.e. a procedure you have
    > to go through) then a procedural programming language could be better.
    > (This is much more of a guideline than a rule.)


    > Python and C++ are OO/procedural hybrids, and can be programmed either
    > way.


    That is all excellent information but I may require more information about
    the significance between Object v Procedure.

    I gather from you description so far that with a GUI you have 'objects' like
    OpenWindow and ScrollWindow etc. Procedure could be compared more to
    assembler where all the tasks are suitabley known and anticipated.

    The same would be applicable to games where dozens/hundreds of
    activities 'objects' are taking place on a constantly updating dataset.

    OK - I have some work to do.

    I think I must begin again by studying up on assembler again, this time
    Linux style.

    Thanks again for your advice.

    BJ

  9. Re: Wanting Advice Please...

    Blazar Jet wrote:
    >Ok. Is most of this online or am I going to be buying a lot of books?


    "Print is dead." --Egon Spengler, Ghostbusters

    It's really rare I buy a computer book anymore. Virtually everything's
    online, from reference to tutorial. Wikipedia is a great source for
    general information, plus links to specific information. A Google
    search will yield tons of hits, e.g.:

    Results 1 - 10 of about 259,000 for "javascript tutorial".

    -Beej


  10. Re: Wanting Advice Please...

    Tom N wrote:
    > Better to start with bash. That way he'll learn how to run his computer
    > without KDE or the like at the same time he's picking up the basics
    > of programming.


    Once again Tom assumes he is the only one that knows how to use the
    shell and everybody else is void of that knowledge.. Good one Tom.

  11. Re: Wanting Advice Please...

    Blazar Jet wrote:
    > I would like to learn how to program.
    >
    > Where should I start?
    >
    > C
    > C++
    > Ruby
    > Python
    >
    > If I learn to program in C, will that screw me up learning C++?
    >
    > All advice is welcome.
    >
    > Thank you.
    >
    > BJ


    Hi Blazar,

    What platform/operating system are you looking at programming for? I'd
    discourage scripting as a guide to learning the basics of programming as
    its not writing REAL code! Scripting is as close to writing REAL code as
    is writing autoexec.bat for DOS.

    Seeing as you have said, that you have learnt assembly language, you
    already have a great head start on what programming is actually about,
    and what is happening inside the computer, thats a huge advantage over
    nubs that walk into the programming world and start with a HLL and think
    they know everything. I'd recommend C as a next step if you want to go
    the high level way. And of course, there is nothing to stop you from
    linking your C with snippets of assembly code or using inline assembly.
    Assembly is still used under unix, same way it was used under DOS, you
    would just call int 0x80 instead of int 0x21 under DOS. MPlayer is a
    great example of a C and assembly language ****tail Tools like Nasm
    are there for writing assembly (or you can use Gas, but you will have to
    learn that disgusting at&t asm syntax), and gcc is the universal C
    compiler on unix systems (also ported to DOS as djgpp).

    C programs can be ported to many platforms with ease (providing they
    don't issue tonnes of exclusive calls to a platform specific API. C++
    can produce some very BLOATED and slow code, and isn't really always
    necessary if you plan on writing programs that just run in the text mode
    shell. I'd only go near C++ if its absolutely necessary (ie: You're
    writing something for a GUI etc, or need to interface with some other
    library in C++)

    C is an incredibly versatile language, so it gets my vote.

    My coding experiences first started with C in the early 90's and I
    initially had trouble learning C and what pointers really were etc, but
    I had seen some amazing stuff done in assembly and veered off course and
    learnt assembler in my own time, when I came back to learning C, it was
    a piece of cake, the missing piece of the puzzle was now in place.

    Alex

  12. Re: Wanting Advice Please...

    Blazar Jet wrote:
    > I would like to learn how to program.
    >
    > Where should I start?
    >
    > C
    > C++
    > Ruby
    > Python
    >
    > If I learn to program in C, will that screw me up learning C++?
    >
    > All advice is welcome.
    >
    > Thank you.
    >
    > BJ


    As a long time sysadmin, who's recently moved over to the application
    development side, here's my 2 cents.

    WHAT do you want to program? If you want to write a mouse driver, you
    need C. If you want to make interactive web pages, then Python, Perl,
    or even asp. Think of a programming language as a tool - sometimes, the
    answer is Visual Basic, sometimes the answer is bash.

    Do you have a job? If so, your choice of language will likely be
    dictated to you. For example, I'm off on parental leave from work, but
    when I go back, I'm on a new team that will be doing legacy support for
    our OpenVMS boxes, which means I'll be learning VMS BASIC. (It's ok, I
    sort of volunteered for it because I thought it would be interesting.)

    I suggest learning them all eventually.

    I think you can start anywhere, but I do recommend learning as low of a
    level as possible, even if it's only "Hello World" in assembler. Why?
    Learning what a stack is, what pointers are, how memory management
    works, etc... all helps to optimize how you do things in a higher level
    language.

    On my bookshelf of "programming language books I'm reading" I have a
    smattering of C, assembler, Python, Pearl, VB, Java, Microsoft SQL. I
    also have Code Complete, The Pragmatic Programmer, Dreaming in Code, The
    Mythical Man-Month. I plan on adding some C++ books, and the Art of
    Programming Series.

    One web site I go to that's entertaining (even if windows biased) is
    codinghorror.com. One funny comment made every halloween - if you want
    to see scary, look at code you wrote 5 years ago.

    Most of all, pick one and have some fun. You learn by reading, you
    learn by doing. And, if you don't manage to blow yourself up once in a
    while, you're not trying hard enough.

    Ray

  13. Re: Wanting Advice Please...

    Blazar Jet wrote:
    >
    > I am nearing retirement and looking to increase my understanding.
    >
    > Who knows, maybe write the Great American Program.
    >
    > Thanks for your input.
    >
    > BJ


    you're like me for sure... think of a program you'd like to write, or
    even one you'd like to extend. That will help pick the language.

    Let's say you like xmms, but want to write a rating plugin like iTunes
    has. You'd need to look at xmms's source and see how to extend it.
    IIRC, that's C++.

    What does your computer do that you wished it did better - or doesn't do
    at all that you'd like it to do? That's even how Linus got started on
    Linux - he wanted a free unix kernel to hack around on.

    Ray

  14. Re: Wanting Advice Please...

    On Tue, 22 Jan 2008 19:53:44 GMT, Blazar Jet wrote:

    >I think I must begin again by studying up on assembler again, this time
    >Linux style.


    Uh, that'd be kernel programming in C then

    One doesn't really do assembler on unix. Well, just a little, see LKML.

    'Cos you see, C and unix grew up together.

    Grant.
    --
    http://bugsplatter.mine.nu/

  15. Re: Wanting Advice Please...

    On Tue, 22 Jan 2008, Mark South wrote:

    >
    > Programming isn't about a particular language. It's a way of thinking.



    --
    William Hunt, Portland Oregon USA

  16. Tower of Babel Re: Wanting Advice Please...

    Blazar Jet wrote:
    > I would like to learn how to program.
    >
    > Where should I start?


    Read the thread and it looks like 'crying in wilderness' as you get
    responses from every imaginable 'mother tongue' of the responder.
    So I will join in.
    Start with something basic and invest the time till you can 'speak
    freely', the transfer to any other language will be a calculated
    decision then, understanding why and what for.
    My way was influenced by then 'new' Borlands TurboPascal v.3 which could
    have 128 letters long names of variables and programming for non-english
    speaking users it was very convenient to represent variables in long
    'Camel style' names.

    > If I learn to program in C, will that screw me up learning C++?


    If you _want_ to learn, nothing can stop you.

    Have fun

    Stanislaw
    Slack user from Ulladulla

  17. Re: Tower of Babel Re: Wanting Advice Please...

    On Wed, 23 Jan 2008, Stanislaw Flatto wrote:

    > If you _want_ to learn, nothing can stop you.


    Very true..

    When employing someone with programming abilities (for an
    internet service) I look for and probably in this order -

    perl
    python
    php
    C++

    It depends on what area you want to enter, like if you want to program
    games, no point in learning php or perl


    --
    Cheers
    Res

    mysql> update auth set Framed-IP-Address='127.0.0.127' where user= 'troll';

  18. Re: Wanting Advice Please...

    Blazar Jet wrote:
    > I am approaching retirement after ~30 years in comp tech hardware and would
    > like to perhaps donate some time helping around some of the FOSS projects,
    > cleaning up code, writing docs, that sort of thing.


    That's the info we needed. Find projects you want to help, find out
    what they need done, and try to help out. That will determine what
    you need to learn.

    If you were just starting a career, I may have answered completely
    differently.

    - Daniel

  19. Re: Wanting Advice Please...

    On Tue, 22 Jan 2008 07:44:25 +0000, Blazar Jet wrote:

    > I would like to learn how to program.
    >
    > Where should I start?


    Turbo Pascal (for DOS).


    --
    "Ubuntu" -- an African word, meaning "Slackware is too hard for me".


  20. Re: Wanting Advice Please...

    Dan C wrote:
    > On Tue, 22 Jan 2008 07:44:25 +0000, Blazar Jet wrote:
    >
    >> I would like to learn how to program.
    >>
    >> Where should I start?

    >
    > Turbo Pascal (for DOS).


    Why not debug.exe for DOS? :P U can code there too

+ Reply to Thread
Page 2 of 3 FirstFirst 1 2 3 LastLast