Member Avatar

Hello World!

I am a new student to Java. and I find it interesting since I never programmed anything but struggling a bit.

I have the book Java: How to program, 8th edition.

and we started in loops today. and he asked us how to make
int j = 1;
into something else more easy to read, after sitting and trying to figure out, my brain hurts. I don't know what he means by making int j = 1; into another format.

Recommended Answers

maybe have it declared and set separately

int j;


j = 1;
Jump to Post

All 2 Replies

maybe have it declared and set separately

int j;


j = 1;

Perhaps he means something more descriptive and meaningful than 'j'. If 'j' were being used as a line counter for example, using 'lineCount' would be easier to follow than 'j', which itself has no intuitive meaning.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.