Jump to content
Ghost Recon.net Forums

Recommended Posts

So lemme try this out, in Java, the whole "an object is an instance of a class" thing. This is kinda similar except from the code you are including these headers which have all this information and code to setup variables and so on in them? Does that make sense?

Link to post
Share on other sites
learn some BASIC

learn some C

if you're learning, start with anything that is OOP based. learning logic and program flow can be done in any language. Starting with OOP instead of migrating to it will make your future programming experiences conceptually easier.

That said, C is still used by professionals, esp in game coding, so being familiar with C wouldn't hurt at all.

Link to post
Share on other sites

It seems like the colleges are starting out with Java. Is this the case that most of you who have started out recently seen? I assume this is because it is Object Oriented.

http://www.cs.nps.navy.mil/people/faculty/...97/java_ans.htm

Article my Java teahcer gave the class.

Something to think about when you are paying all that money for your Java class.

Link to post
Share on other sites

Quote from article:

In horrible C tradition, Java arrays start from zero, instead of one. How many future programmers will spend hours locating off-by-one errors? What is wrong with the number one?

This is SO true. I've been studying graph algorithms, search algorithms, sort algorithms, I'm up to my eyeballs in algorithms and let me tell you, if I had a dollar for every time I was off on my index by one...... grrrrrr

Link to post
Share on other sites

It is a number but it is a lot easier to understand when you start at one.

It is just easier for people to think starting at one than zero. Think about it. When you start counting you don't start at zero do you?

Link to post
Share on other sites
It is a number but it is a lot easier to understand when you start at one.

It is just easier for people to think starting at one than zero.  Think about it.  When you start counting you don't start at zero do you?

Not out loud, no. But you can and some do when counting money, and everything related to a PC can or does start with a zero; zero actually counting as a number.

Zero doesn't mean 'nothing' in the computer world.

Link to post
Share on other sites
But aren't we talking about a computer language used by people?

We're talking about a computer language used by computers, but is entered by people. Subtle difference. Zero is a logical character, and computers are logical by design, thus programmers have to work with the inherent logic of the hardware/software when writing code.

To put it this way: In English, other than pronouns, gender has no role. In French, nouns are masculine or feminine. In German, it's like French, but there are Neutral gender words. The speaker must adapt their format to suit the platform/language/nation/whatever they are communicating with.

Link to post
Share on other sites

Maybe the only problem that I have is the variable lenght that is created when the array is created. It is set to the value that you say i.e. (int[] i = new int[25]) lenght will be 25 while the array only goes from 0-24.

Edited by Matt03
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...