Click here to Skip to main content
15,507,755 members
Home / Discussions / Java
   

Java

 
AnswerRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
Richard MacCutchan27-Oct-20 6:24
mveRichard MacCutchan27-Oct-20 6:24 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
User 1494142127-Oct-20 6:39
User 1494142127-Oct-20 6:39 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
User 1494142127-Oct-20 6:38
User 1494142127-Oct-20 6:38 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
Richard MacCutchan27-Oct-20 6:42
mveRichard MacCutchan27-Oct-20 6:42 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
User 1494142127-Oct-20 6:46
User 1494142127-Oct-20 6:46 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
Richard MacCutchan27-Oct-20 6:56
mveRichard MacCutchan27-Oct-20 6:56 
GeneralRe: Using for loop create a bluej program for the question( https://1drv.ms/u/s! Ajrld_fzlfykhx8hc1sbkiufuc_p ) Pin
Richard MacCutchan27-Oct-20 8:10
mveRichard MacCutchan27-Oct-20 8:10 
AnswerRe: Write a program using for loop that computes sinx and cosx by using the following power series- sinx=x-x^3/3!+x^5/5!-x^7/7!+.... cosx=1-x^2/2!+x^4/4!-x^6/6!+..... Note-(Here ! is used for factorial of that number and ^ for "power of" Pin
Patrice T6-Nov-20 16:59
mvePatrice T6-Nov-20 16:59 
Quote:
My problem is that I am not understanding that whether the source code I wrote is correct or not

Your code do not behave the way you expect, or you don't understand why !

There is an almost universal solution: Run your code on debugger step by step, inspect variables.
The debugger is here to show you what your code is doing and your task is to compare with what it should do.
There is no magic in the debugger, it don't know what your code is supposed to do, it don't find bugs, it just help you to by showing you what is going on. When the code don't do what is expected, you are close to a bug.
To see what your code is doing: Just set a breakpoint and see your code performing, the debugger allow you to execute lines 1 by 1 and to inspect variables as it execute.

Debugger - Wikipedia, the free encyclopedia[^]

Mastering Debugging in Visual Studio 2010 - A Beginner's Guide[^]
Basic Debugging with Visual Studio 2010 - YouTube[^]

1.11 — Debugging your program (stepping and breakpoints) | Learn C++[^]

The debugger is here to only show you what your code is doing and your task is to compare with what it should do.
Patrice

“Everything should be made as simple as possible, but no simpler.” Albert Einstein

AnswerInterview Question locking for Ans Pin
sureshkct26-Oct-20 5:52
sureshkct26-Oct-20 5:52 
QuestionRe: Interview Question locking for Ans Pin
Richard MacCutchan26-Oct-20 6:34
mveRichard MacCutchan26-Oct-20 6:34 
GeneralRe: Interview Question locking for Ans Pin
Dave Kreskowiak27-Oct-20 7:54
mveDave Kreskowiak27-Oct-20 7:54 
QuestionJAVA IF ELSE STATEMENT (HELP ME) Pin
tomatomoa24-Oct-20 8:45
tomatomoa24-Oct-20 8:45 
AnswerRe: JAVA IF ELSE STATEMENT (HELP ME) Pin
Sandeep Mewara24-Oct-20 9:17
mveSandeep Mewara24-Oct-20 9:17 
GeneralRe: JAVA IF ELSE STATEMENT (HELP ME) Pin
tomatomoa3-Nov-20 3:18
tomatomoa3-Nov-20 3:18 
GeneralRe: JAVA IF ELSE STATEMENT (HELP ME) Pin
Richard MacCutchan3-Nov-20 4:11
mveRichard MacCutchan3-Nov-20 4:11 
QuestionLooking for a node.js developer for advanced disk wiping software (Almost complete) Pin
fixapc22-Oct-20 6:45
fixapc22-Oct-20 6:45 
AnswerRe: Looking for a node.js developer for advanced disk wiping software (Almost complete) Pin
Richard MacCutchan22-Oct-20 7:09
mveRichard MacCutchan22-Oct-20 7:09 
QuestionLog4j2 Migration Pin
Member 1496731916-Oct-20 5:21
Member 1496731916-Oct-20 5:21 
AnswerRe: Log4j2 Migration Pin
Richard MacCutchan16-Oct-20 5:38
mveRichard MacCutchan16-Oct-20 5:38 
QuestionJackson ObjectMapper valueToTree method also write valueType and integral but no actual value Pin
Manish K. Agarwal12-Oct-20 0:02
Manish K. Agarwal12-Oct-20 0:02 
QuestionWhy can't we make a sign up with phone number in android studio project Pin
Member 145474583-Oct-20 3:46
Member 145474583-Oct-20 3:46 
Question2d java graphics Pin
Member 149532531-Oct-20 3:07
Member 149532531-Oct-20 3:07 
AnswerRe: 2d java graphics Pin
CHill601-Oct-20 3:09
mveCHill601-Oct-20 3:09 
AnswerRe: 2d java graphics Pin
Richard MacCutchan1-Oct-20 4:02
mveRichard MacCutchan1-Oct-20 4:02 
Questionjava programmimg Pin
Member 1494135617-Sep-20 20:36
Member 1494135617-Sep-20 20:36 

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.