Arrays and their structure

Blitz3D Forums/Blitz3D Beginners Area/Arrays and their structure

seferey(Posted 2005) [#1]
Hello I'm very confused on writing the array in my program

in a structure as well as the info you put into them corretly


Rob Farley(Posted 2005) [#2]
I wrote a little explaination of arrays the Wolron 'borrowed' and added to for his site

http://home.cmit.net/rwolbeck/programmingtutorial/reference/arrays.htm


WolRon(Posted 2005) [#3]
You seem a bit bitter, Rob...

I suppose (when I get time) I should rewrite it so that it's not using the parts that you wrote...


morduun(Posted 2005) [#4]
Ah you mean like the frame-limiting tut he 'borrowed' from my Blitzcoder tut here?

http://home.cmit.net/rwolbeck/programmingtutorial/index.htm

I note a trend.

That said, the link Rob posted should straighten you out with standard arrays -- post more specific questions if you still have em after reading that.


WolRon(Posted 2005) [#5]
morduun, I don't know what you are on about, but I never 'borrowed' any tut regarding frame-limiting. I wrote that one from scratch, entirely myself.

It's very possible that I learned about how to frame-limit code in Blitz from your tutorial on BlitzCoder, but I certainly didn't copy it (or 'borrow' it, as you say).

The only person here that can say that I copied their work, is Rob Farley. And the only reason he can say that, is because I asked him if it was OK to do so, and he never replied. Because he never said "No", I never took it off the site. If he had, I certainly would have immediately removed it and written my own. FYI, it's mostly written by me anyways, I just copied the part about the "chess board versus multiple arrays" example.


seferey(Posted 2005) [#6]
how many arrays can you make in one program?


WolRon(Posted 2005) [#7]
As many as the computer will allow depending on memory. So, in other words, millions...


seferey(Posted 2005) [#8]
also when writing the word Dim (8) can you put any thing
you write in between Dim and (8)


WolRon(Posted 2005) [#9]
You can use any normal name that you can use for most other identifiers.

It's the same format as for other variables. Check out how to format identifiers at my programming tutorial where I talk about variables.


Rob Farley(Posted 2005) [#10]
You seem a bit bitter, Rob...
Not at all, however, seeing as I've asked you in the past to credit me for the writing of it and you didn't I think it's just a little rude.


seferey(Posted 2005) [#11]
is there a limit of numbers used in Dim fdsfsdf (8)
can you write 1000 or 10000 in the (8)


Rob Farley(Posted 2005) [#12]
Yes there is a limit, blitz only seems to allow a certain amount of bytes per array. The thing to do is have a play.


WolRon(Posted 2005) [#13]
Actual thread that we both posted our array descriptions in:
http://www.blitzbasic.com/Community/posts.php?topic=35512&hl=chess array
You'll notice that I wrote a large part of it myself...

And here is the thread where I asked if you wanted me to give you credit, BUT YOU NEVER RESPONDED, just like I said above...
http://www.blitzbasic.com/Community/posts.php?topic=37661&hl=chess array

Quoted by me...
If you would like me to remove it from my tutorial then I will. I just thought that you did a well enough job explaining it that it wasn't necessary for me to rewrite it. Nor did I feel that it was necessary to include a page of names of people that I might have borrowed text from - people who to most readers would probably just be nobodys anyways.

However, if you would like me to still use it in my tutorial but give you credit somewhere, then I can do that too.


So PLEASE don't accuse me of doing something I didn't do.

Take note here, on another page on my site, where I DID give credit to the person that wrote some of the information on the site (The Copyright and Trademark FAQ by Black3D):
http://myweb.arvig.net/rwolbeck1/Reference/references.htm


So, once again,

Would you like me to remove it from my tutorial?
Or leave it in my tutorial, and just give you credit for it?

Your choice.


Rob Farley(Posted 2005) [#14]
Credit would be spendid.


WolRon(Posted 2005) [#15]
OK, I will do that, as well as give credit to Big10p, when I rewrite it...

EDIT: Credit given.


seferey(Posted 2005) [#16]
Hey um Wolron is it? what other words do you use for identifiers


WolRon(Posted 2005) [#17]
Well, like I said above, the kinds of names you can use are listed on my variables page.

Reposted here:
Variables have names to differentiate themselves from other variables.

You can name a variable anything you want such as:
variable, variable2, apple, answer, lljwjdiisen3mm, AVeryLongNameThatUsesCapsSoYouCanReadIt, Q, Jamie, tree, etc.
as long as the name of the variable meets these three conditions:

it starts with a letter,

it has no spaces, or special characters

it isn't the same as a word already used by the BASIC language (such as Print, or Delay).


and this is what it states in your Blitz Basic Language Reference on Identifiers:
Identifiers are used for constant names, variable names, array names, function names and custom type names.


Identifiers must start with an alphabetic character, and may be following be any number of alphanumeric characters, or the underscore ('_') character.

These are all valid identifiers:



- Hello

- Score

- player1

- time_to_live

- t__




Indentifiers are not case sensitive.


For example, 'Test', 'TEST' and 'test' are all the same identifiers.


However, it is allowed for identifiers to be reused for functions and custom types names.


For example, you can have a variable called 'test', a function called 'test' and custom type name called 'test'. Blitz will be able to tell which one you are refering to by the context in which it is used.