I learned how to program in Java my freshman year in high school. However, i didn't continue to learn programming, mainly because I still didn't know what I wanted to do. It's now my freshman year in college (ironic) and I've decided to pick it back up. Right now, i'm reading the tutorials on cprogramming.com and I've gotten the hang of the basics again (cin, cout, strings) and I'm trying to wrap my head around some of these other concepts.
First, what purpose do arrays serve, namely a program with this sort of code:
#include <iostream>
using namespace std;
int main()
{
int x;
int y;
int array[8][8];
for ( x = 0; x < 8; x++ )
{
for ( y = 0; y < 8; y++ )
array[x][y] = x * y;
}
cout<<"Array indices:\n";
for ( x = 0; x < 8; x++ )
{
for ( y = 0; y < 8; y++ )
cout<<"["<<x<<"]["<<y<<"]=" << array[x][y] << " ";
cout<<"\n";
}
cin.get();
}
The final thing that I would ask to you guys is this: what sort of programs should I write for practice? Keep in mind my knowledge is limited as far as syntax goes, but if you guys could give me some ideas, it'd help me practice. Unless theres a topic for that already... So far the only thing I can come up with is a simple choose your own adventure text based game.