Click here to Skip to main content
15,937,008 members
Home / Discussions / Java
   

Java

 
GeneralRe: The main purposes of learning java Pin
Ratul Thakur8-Jul-16 1:05
Ratul Thakur8-Jul-16 1:05 
GeneralRe: The main purposes of learning java Pin
Richard MacCutchan8-Jul-16 3:05
mveRichard MacCutchan8-Jul-16 3:05 
GeneralRe: The main purposes of learning java Pin
Ratul Thakur8-Jul-16 1:03
Ratul Thakur8-Jul-16 1:03 
GeneralRe: The main purposes of learning java Pin
Pratik Temkar3-Aug-16 3:32
Pratik Temkar3-Aug-16 3:32 
Questionsimple question nested for loop to solve array problem Pin
Member 1259386520-Jun-16 4:29
Member 1259386520-Jun-16 4:29 
AnswerRe: simple question nested for loop to solve array problem Pin
Richard Deeming20-Jun-16 5:46
mveRichard Deeming20-Jun-16 5:46 
GeneralRe: simple question nested for loop to solve array problem Pin
Member 1259386520-Jun-16 8:04
Member 1259386520-Jun-16 8:04 
GeneralRe: simple question nested for loop to solve array problem Pin
Richard Deeming20-Jun-16 9:09
mveRichard Deeming20-Jun-16 9:09 
j doesn't start with 1; it starts with i, and then increments for each pass of the inner loop.
i = 0
    j = 0    a[i] = 4; a[j] = 4
    j = 1    a[i] = 4; a[j] = 2    // <-- Your condition is met here
    j = 2    a[i] = 4; a[j] = 7

i = 1
    j = 1    a[i] = 2; a[j] = 2
    j = 2    a[i] = 2; a[j] = 7

i = 2
    j = 2    a[i] = 7; a[j] = 7

You really need to learn to use a debugger. Rather than trying to guess what your code is doing, step through it line by line and examine the values of the variables.



"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer


GeneralRe: simple question nested for loop to solve array problem Pin
Member 125938652-Jul-16 17:52
Member 125938652-Jul-16 17:52 
Question3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
zarkerBlack20-Jun-16 0:43
zarkerBlack20-Jun-16 0:43 
AnswerRe: 3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
Richard Deeming20-Jun-16 1:40
mveRichard Deeming20-Jun-16 1:40 
GeneralRe: 3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
zarkerBlack20-Jun-16 3:09
zarkerBlack20-Jun-16 3:09 
GeneralRe: 3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
Richard MacCutchan20-Jun-16 4:00
mveRichard MacCutchan20-Jun-16 4:00 
GeneralRe: 3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
zarkerBlack21-Jun-16 3:17
zarkerBlack21-Jun-16 3:17 
GeneralRe: 3 x 3 plane,clockwise or counterclockwise rotate the four tiles Pin
Richard MacCutchan21-Jun-16 3:25
mveRichard MacCutchan21-Jun-16 3:25 
QuestionSerializing object to disc. Only retreives one object. Pin
larsp77714-Jun-16 1:42
larsp77714-Jun-16 1:42 
AnswerRe: Serializing object to disc. Only retreives one object. Pin
Richard MacCutchan14-Jun-16 3:47
mveRichard MacCutchan14-Jun-16 3:47 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
larsp77714-Jun-16 22:22
larsp77714-Jun-16 22:22 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
Richard MacCutchan14-Jun-16 22:47
mveRichard MacCutchan14-Jun-16 22:47 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
larsp77714-Jun-16 23:28
larsp77714-Jun-16 23:28 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
Richard MacCutchan14-Jun-16 23:39
mveRichard MacCutchan14-Jun-16 23:39 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
larsp77714-Jun-16 23:52
larsp77714-Jun-16 23:52 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
Richard MacCutchan15-Jun-16 0:43
mveRichard MacCutchan15-Jun-16 0:43 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
larsp77716-Jun-16 21:28
larsp77716-Jun-16 21:28 
GeneralRe: Serializing object to disc. Only retreives one object. Pin
Richard MacCutchan16-Jun-16 22:16
mveRichard MacCutchan16-Jun-16 22:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.