WT-Fakawi
2011-03-08 06:53:00
…like this:
46234523, 3467347, 89078967, 12341234, 678995689, 12341234, 7898,
On one line (comma separated).
46234523, 3467347, 89078967, 12341234, 678995689, 12341234, 7898,
On one line (comma separated).
2011-03-08 06:53:00
2011-03-08 06:57:05
procedure meow(arr: TintegerArray);
var i: integer;
s: string;
begin
for i := 0 to high(arr) do
s := inttostr(arr[i] + ", "
writeln(s);
end;
2011-03-08 06:57:46
2011-03-08 06:58:04
2011-03-08 07:08:33
2011-03-08 07:18:00
2011-03-08 14:16:26
From: ReadySteadyGo
^ with that you do get [ ] but I guess that shouldn't be an issue.
procedure WriteIntArrayWithoutBrackets(arr:TIntegerArray);
var
str: string;
begin
str := ToStr(arr);
Writeln(Between('[', ']', str));
end;
2011-03-08 14:19:28
From: lordsaturn
procedure WriteIntArrayWithoutBrackets(arr:TIntegerArray);
var
str: string;
begin
str := ToStr(arr);
Writeln(Between('[', ']', str));
end;
2011-03-08 14:28:38
From: Frement
And you don't need the temp variable. But yeah, I would think the brackets wont matter.
2011-03-08 18:23:12
2011-03-08 19:50:48
From: lordsaturn
Thanks for the advice Frement. You forget your place I put it there so that fawk would realize how easy it is to print an array or any other data type within simba using just ToStr.
2011-03-09 07:26:57
From: lordsaturn
Thanks for the advice Frement. You forget your place. I put it there so that fawk would realize how easy it is to print an array or any other data type within simba using just ToStr.
2011-03-09 14:08:32
From: Frement
I wasn't trying to be hostile. I realize that readability is important, and that you probably knew already the thing I posted, but still. I don't know if you got it wrong what I was meaning, ofcourse I know you were showing ToStr, but I was talking about the temporary string variable, you could just have given it straight to the between function.
2011-03-09 14:23:31
From: lordsaturn
And what made you think I didn't realize that?
2011-03-09 14:26:40