SRL Archive - Help

idk what im doing rong and im getting very confused


joehartwig

2012-01-26 13:49:23

what am i doing rong here in this pic and thanks :cartman:

slakan

2012-01-26 13:52:31

end;
end;
end.

joehartwig

2012-01-26 13:59:51

sorry i dont get what u mean can u show me what the full thing should look like?

Caotom

2012-01-26 15:07:18

Basically the procedure needs an entirely seperate begin and end.

What you would want is:
program NAME;

procedure TypeInDebug;
begin
Writeln('Hello World');
end; //Notice the semicolon on the end?

begin //This is where you 'call' all your procedures
TypeInDebug;
end. //Notice the full stop after the end? This is only for the main loop, all procedures have a ; after the end

Hope this helped and good luck with learning simba :)
~Caotom

superuser

2012-01-26 16:37:18

From: Caotom
…

Hope this helped and good luck with learning simba :)
~Caotom


This is not about learning Simba, but learning the basics of Pascal programming language. Luckily, Pascal is ALGOL based language. It was originally intended to teach students programming (so it has easy syntax and learning curve).

I suggest you to read through this for starters.

joehartwig

2012-01-27 00:29:31

thanks for the help and yes i am slowly learning how to do the basics im still verry new to this and im the type of person that need a "babysitter" when doing stuff like this to ask a billon time if im doing it right and to check over my work

joehartwig

2012-01-27 00:31:55

do i put in the "//notice the semicolon in the end?"

superuser

2012-01-27 02:48:47

From: joehartwig
do i put in the "//notice the semicolon in the end?"


No, that's just a comment in the code. There's two type of them, one-line and block.

A block comment would be like this:


...

{ This is a comment. This block will be ignored by
the compiler/interpreter. }

for i := 0 to 9 do begin // This is a one-line comment, which is also ignored after // -mark.
end;