Welcome, Guest. Please login or register.

Author Topic: Beginner Programing  (Read 3243 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline melottTopic starter

  • Hero Member
  • *****
  • Join Date: Dec 2002
  • Posts: 989
    • Show only replies by melott
Beginner Programing
« on: February 22, 2003, 04:47:25 PM »
From one beginner to any others....
There was another thread started by someone
asking the best way to get started programing.
He received advice on everything from Fortran
to Java.
I wouldn't be supprised if he gives up.
Since I am a beginner I can relate to his problem.
Nobody said anything that was very helpful (IMHO).
I wanted to start programing, and I have several
options open to me. I have numerious manuals
languages ether perched or given to me,all legal.
And the route I chose to take was to start with
AmigaBasic. And yes I know its CRAP, but its also
probably the most documented. Books and example
code both good and bad are very easy to find.
When I started school and they tought me to read
they didn't give me the book "War & Peace" to learn
from, they gave me "Dick & Jane see Spot run".
My opinion is to start with AmigaBasic and except
the scoffs and Boo's. Its the easiest way.
There is no substatute manuals and there is probably more writen on basic than any other.
AmigaBasic will run on your Classic Amiga.
I have an A3000, 3.1 OS, A3640 accelerator and
a Retina Z2 gfx card and it runs quite well.
I have moved on to Blitz2 now, AmigaBasic can
only take you so far than you have to move on.
Maybe "C" will be next or maybe not, I don't know.
I am enjoying my self, not racking my head with
"Information Overload" that I would be getting
tring to learn "C".
Its very difficult to try to understand a concept
if you don't even know what the concept is that
you are tring to understand.
So start small, AmigaBasic or AREXX.
You'll know when you are ready to move up.

 (IMHO)
Mel Ott

 :-)  :-)
Stealth ONE  8-)
 

Offline alx

Re: Beginner Programing
« Reply #1 on: February 22, 2003, 05:07:24 PM »
I agree with you on most of that.  Here's my advice on learning to program...

Despite what many people say, Basic is still a very good language to start with, and most Basic languages behave the same for simple stuff like  string handling.  The main gripe that people have with AmigaBasic is that it isn't very compatible.  A better solution is to look around and find a small freeware Basic (there are plenty around).  This should be compatible with AmigaBasic, and with your system!

Once you can program well in any Basic, you can then move onto something like C.  My advice is NOT to use somehing like AMOS.  It was great when it was new, but really shows its age now.  The advantage to AMOS was the ability to make nice effects using lots of high level commands.  AMOS doesn't even support AGA!

Offline Targhan

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 818
    • Show only replies by Targhan
    • http://www.geocities.com/targhan_aga
Re: Beginner Programing
« Reply #2 on: February 22, 2003, 06:04:58 PM »
I agree with the concepts, but I feel that someone who's never coded a line at all should start at the very beginning.  On an Amiga, that would be an AmigaDOS script.

Between AmigaDOS and IconX, a beginner can see result immediately.  Once a few scripts have been written they can move to Basic, ARexx, or any number of other "beginner" languages.

Example:

From OS3.5's (or above) EditPad, type the following:

avail flush

Save the file(call it GarbageCollector); then, open the icon-information.  Where the default tool says "EditPad," type IconX in it's stead.  (If your system is not set up correctly, you may have to give the path to IconX).  

Now, you have your first program that actually does something!  Double click on GarbageCollector and marvel at the program you created!  :-)


Regards,
Targhan
 

Offline takemehomegrandma

  • Hero Member
  • *****
  • Join Date: Oct 2002
  • Posts: 2990
    • Show only replies by takemehomegrandma
Re: Beginner Programing
« Reply #3 on: February 22, 2003, 06:14:37 PM »
@ Targhan

Quote
I agree with the concepts, but I feel that someone who's never coded a line at all should start at the very beginning.


You mean the C64?  :-D

The CommodoreOne is soon coming to a desk near you! :-)
MorphOS is Amiga done right! :)
 

Offline Targhan

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 818
    • Show only replies by Targhan
    • http://www.geocities.com/targhan_aga
Re: Beginner Programing
« Reply #4 on: February 22, 2003, 06:29:10 PM »
load ,8,1
Regards,
Targhan
 

Offline iamaboringperson

  • Hero Member
  • *****
  • Join Date: Jun 2002
  • Posts: 5744
    • Show only replies by iamaboringperson
Re: Beginner Programing
« Reply #5 on: February 22, 2003, 08:10:58 PM »
@melott

Quote
And the route I chose to take was to start with
AmigaBasic

and the experienced ones are telling you NOT to start with basic, they were beginners once too!
heck, I started with basic, when i was a kid, but i wish i had of started with C++!
Quote
And yes I know its CRAP, but its also
probably the most documented. Books and example
code both good and bad are very easy to find.

no, these days C & C++ have much more & better documentation...
Quote
When I started school and they tought me to read
they didn't give me the book "War & Peace" to learn
from, they gave me "Dick & Jane see Spot run".
My opinion is to start with AmigaBasic and except
the scoffs and Boo's. Its the easiest way.

C/C++ is not like war and peace, if you start learning C/C++/Java you will eventually find that out

void main(void)
{
printf("this is Dick and Jane see Spot run, trust me");
}

start with the simplest of c programs, and gradually work your way up, you have no idea how easy it is
the easiest way is NOT to learn a procedual language, & procedual programming techniques, and then to learn a structured or OOP language, unlearning all your old habbits
the easy way to programming it to concentrate on ONE language - TRUST THOSE WHO KNOW
Quote
I am enjoying my self, not racking my head with
"Information Overload" that I would be getting
tring to learn "C".

its not info. overload if you take it one step at a time
its like eating an elephant
 :-)  :-)
 

Offline Step

  • Full Member
  • ***
  • Join Date: Feb 2002
  • Posts: 202
    • Show only replies by Step
Re: Beginner Programing
« Reply #6 on: February 22, 2003, 08:31:40 PM »
I really would like to start with C myself, but theres always the small stuff that causes problems, like a book that focuses on a different OS and compiler, small differences that makes stuff really hard for an inexperienced person.

There is no obvious place for an Amiga owner to start from scratch, very little material and even less courses etc...

If/when OS 4 is released it would be totally awsome if some experienced coders could get together and focus on teaching C/C++ programming and really figure out new ways to teach people without a coding background. (Courses could mean revenue) :-D

Obviously, the  folks at Amiga and Hyperion really should make an effort to promote development aswell as it could boost the platforms viability.
.................................
 :sealed: Think, before :ranting:
 

Offline lorddef

  • Hero Member
  • *****
  • Join Date: Apr 2002
  • Posts: 1139
    • Show only replies by lorddef
    • http://
Re: Beginner Programing
« Reply #7 on: February 22, 2003, 09:09:55 PM »
Hmm, I agree basic is a nice little starting point, easier to start off and all, but really once you have gotten your head around the basics of C, or java its just as easy, no forget that its easier.

I would say Java would be just as easy to learn as basic if you started out with no knowledge at all.  With C the main thing you have to get you're head around is memory allocation and pointers, but you can do ####ty little programs like the ones you do in basic without even knowing them.
Restraining orders are just another way of saying I love you!
 

Offline Turrican

  • Jr. Member
  • **
  • Join Date: Mar 2002
  • Posts: 72
    • Show only replies by Turrican
Re: Beginner Programing
« Reply #8 on: February 22, 2003, 09:57:06 PM »
If there is a PC available I would suggest getting one nice copy of the latest Mozilla browser and start practicing your programming skills with JavaScript.

This way you get some beatifull debuging tools, you don't mess with compilers AND you can use the HTML DOM as the the 2D graphic API (wich is far easier to learn than a real language's one).

Beware, though, if you follow this way, FOCUS ON ONE BROWSER (at least for the start...).

Anyway that is the way I started some years ago (Amstrad CPC 6128 Basic 1.1 experience not included! :)) and now with a lot of reading and practicing  I am a profesional...
 

Offline jdiffend

  • Sr. Member
  • ****
  • Join Date: Apr 2002
  • Posts: 302
    • Show only replies by jdiffend
Re: Beginner Programing
« Reply #9 on: February 22, 2003, 10:48:04 PM »
Basic is good to learn simple things like variables, loops and stuff like that.  It gives immediate feedback during execution so you can see some of the common beginner mistakes easily.

The only reason Basic used to be so much easier to learn on was that you didn't have to manage windows and other OS stuff just to print a message to the screen.  It also came with the machine and you could pick up magazines that had dozzens of programs you could type in.  There's nothing quite like typeing in programs and then running them to teach you how things work.  You could run the program and stop it at any time to see what code was executing and you could see how something actually worked a line at a time by stepping through the code.

The most common problem with C is you can't just start programming like basic.  You have to learn about include files, compilers, linkers and object libraries just to print "hello world" on the screen.  

If you have access to a PC, there used to be a C interpreter that would let you do the same thing with C.    Not sure what it was called but you could do the same kind of stuff as Basic.  A search on Google turned up several C interpreters.  CINT works on the console (text only) so it might be worth checking out.

Once you have the basics of programming down you'll want to learn about compilers and object oriented programming.  Compilers first I'd say.  Integrated development environments are a nice way to ease into it but the old Turbo C is a lot easier than the new IDE's.

Java is nice because it prevents you from doing things that would be perfectly legal in C but very undesirable.  However, you dive into the concept of objects rather quickly and the complexity and number of objects could overwhealm you in a hurry without help.
One plus is the availability of free development environments, tools and documentation.

 

Offline jdiffend

  • Sr. Member
  • ****
  • Join Date: Apr 2002
  • Posts: 302
    • Show only replies by jdiffend
Re: Beginner Programing
« Reply #10 on: February 22, 2003, 11:12:10 PM »
Oh yeah, one other thing.  it was much more difficult to crash the machine in Basic than it is in C/C++.  That can be very frustrating for a beginner.  Pointers can be very tricky and can cause you problems even if you've been programming for years.  That's part of the reason so many people like Java.  It doesn't let you poke around in memory like C does.
 

Offline jdiffend

  • Sr. Member
  • ****
  • Join Date: Apr 2002
  • Posts: 302
    • Show only replies by jdiffend
Re: Beginner Programing
« Reply #11 on: February 22, 2003, 11:28:37 PM »
You can find links to free C/C++ Compilers and Interpreters here.

If you have a PC the old Turbo C, Turbo C++ and Turbo Pascal are available free.  Also, a newer Borland C++ compiler is available without the IDE.
 

Offline Ilwrath

Re: Beginner Programing
« Reply #12 on: February 22, 2003, 11:56:07 PM »
I tend to agree that Pascal is underrated at learning on.  It leads easily into C.  (Which also isn't a bad place to start, if you don't mind jumping in the deep end a bit to learn.)  I've also found I like Java a lot, but I learned it late.  (Well after Pascal and C -- so I can't speak on it as to how easy it is to learn from early.)

Whoever recommended Fortran was obviously trying to discourage the poor person.  Hell, I think I'd choose FoxPro or LISP first.  (And I'd only choose either of those if hemlock wasn't available.)

Most people who don't recommend BASIC for starting with, are like me and DID start with BASIC.  I remember having to "unlearn" all sorts of things you can do in BASIC but really shouldn't do in any other language...  Sure... it's easy to learn.  Sort of like slang.  Just because you know it, and it sometimes works, it doesn't mean you should use it on a report...
 

Offline peroxidechicken

  • Full Member
  • ***
  • Join Date: Apr 2002
  • Posts: 170
    • Show only replies by peroxidechicken
Re: Beginner Programing
« Reply #13 on: February 23, 2003, 12:32:38 AM »
Hello Melott.  Don't you hate backseat drivers?  How did you go with AmigaBASIC on your A3000?  

When I started with AmigaBASIC, one of the first programs I tangled with was this:

rem --- mandelbrot set for amigabasic ---
rem --- by tim stepthens 1990 ---
screen 1,640,200,4,2
window 2,"mandelbrot set",,31,1
color 1,2
cls
locate 10,11
input "interations (1 to 1000) ",iter
cls
if iter=0 then iter=25
a:
a=0
for y=0 to 93
for x=0 to 617
b:
zx1=(x-410)/190
zy1=(y-95)/90
zy=zy1
zx=zx1
c:
for a=1 to iter
zy2=zy*zy
zx2=zx*zx
if zy2+zx2>4 then goto d
zy=2*zx*zy+zy1
zx=zx2-zy2+zx1
next a
goto f
d:
d=a mod 16
color d
if d=2 then color 1
e:
pset (x,y)
pset (x,186-y)
f:
next x
next y

 - fractals were all the rage 15 years ago!  But I think the important thing is that it gives some visual feedback - so many program examples for lower level langages don't do that.  
H2O2
 

Offline jdiffend

  • Sr. Member
  • ****
  • Join Date: Apr 2002
  • Posts: 302
    • Show only replies by jdiffend
Re: Beginner Programing
« Reply #14 on: February 23, 2003, 01:27:16 AM »
I know a lot about AmigaBasic.  The problem with AmigaBasic is that it doesn't even run if you have too much memory.  It also does it's share of crashing too.

I used to write libraries for AmigaBasic so that it could do a lot of advanced stuff.  Picture loaders with color cycling, all sorts of sound routines, mod music players... you name it.  The libraries were written in C and assembly.  I *might* still have the docs and examples for the libs somewhere if anyone was actually interested.

If you choose to go with AmigaBasic (which I always thought sucked), try to pick up a copy of  the Absoft Basic compiler (I think that was the one we used).  It worked with most standard code and added some extensions that were nice as you get more advanced.

FWIW, I did some looking around and there is a C interpreter that works like Turbo C.  It's called the Quincy C interpreter.  But it is for the PC.