Can anyone help me in debugging a for loop in netbeans. The issue is that i don’t want to go through all the iterations of the loop but only the 7th iteration and the last iteration. How can i do this??
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You can set a conditional breakpoint in the first line inside the loop.
To define a conditional breakpoint, first create a regular one.
Then right click on the little red square in the left margin and choose “Breakpoint -> Properties”.
Enable the conditions checkbox and add the condition
i == 5in there (assuming your loop index variable is named i)