458 Posted Topics
Re: I suppose you need to ask for the number of grades and then continue looping in the for loop for those many times. Now, if you understand the for loop construct, initialise a counter to 1 and continue it to the number of grades, incrementing it once every time. Think … | |
Re: Obviously, as it appears from your information as also from a google search over the topic, this is a bug in MySQL. And guess what the MySQL people accept this, actually this is bug # 25156. Many people have had this problem. Take a look [URL="http://bugs.mysql.com/bug.php?id=25156"]here[/URL] Edit : The MySQL … | |
Re: Your query should be of the form : [code=sql]SELECT a.fruits FROM tableA a where a.fruit NOT IN (SELECT b.fruit2 from tableB b where b.fruit1 = 'apple') AND a.fruits != 'apple';[/code] This will work provided that 'apples' appear only in the fruit1 column of tableB. Don't expect this query to work … | |
Re: You can use a do while loop to restrict no. of tickets entered from being negative or greater than 100. Ex: [code=java] do{ System.out.println("How many tickets ?"); atickets = keyboard.nextInt(); // check for input being in the range (not < 0 and not > 100) // if input is in … | |
Re: @stephen84s : Yes but in this case, what happens if he inputs the number of adult tickets to be 110 ? You still ask him for the number of child tickets, which since he has already jumped the maximum count is wrong on our part. If he enters the no. … | |
Re: My judgement here is that there was no infinite loop at all. When you are running a GUI based program you don't get to see any exceptions thrown by the JVM. Now, when your index counter was reaching 'size' then the JVM would have been throwing an exception which since … | |
![]() | Re: According to the usage you mention, a stack would be more useful than a queue. Also take a look at this [URL="http://www.daniweb.com/forums/showthread.php?t=170140&highlight=crawler"]thread[/URL]. |
Re: Detail your query, it is very difficult to advice anything from what you have provided, give us the table designs. | |
Re: Java has an [URL="http://java.sun.com/j2se/1.3/docs/guide/awt/designspec/events.html"]Event Delegation Model[/URL]. In short this goes like this. There are Event sources which are components such as Button, Frames, Windows, Textboxes, Text Areas etc. There are Event Listeners which listen to events. Event Listeners need to register to an Event Source so that for any events … | |
Re: @staneja : Atleast care to see the post date, before posting question to him. It's better to start a new thread than to revive a four year old thread. | |
Re: How are you creating the file ? If it is done with an absolute path then we need to see the code to tell you what might be going wrong. If it is created with a relative path in your program then the file certainly won't be created in the … | |
Re: Can anyone guess which country is this ? Mosaa Ceanarim | |
Re: As a suggestion, I would like to tell you that there are some basics to game development. I do not know how the education of your son has been through the learning years, but an understanding (or rather much more an undying interest) is required in Math for someone to … | |
Re: @masijade : You could easily have been a detective, you have the temparament and the ability to look into the slimmest of the crevices. ;) | |
Re: You have already been offered help, only if you care enough to take it. | |
Re: Also just to add to what masijade has explained very well and that too in a very concise manner, calling [icode]System.gc()[/icode] is not exactly considered a good programming practice. Also one question comes to mind here, how do you think you are going to [B][I]destroy[/I][/B] the object ? | |
Re: Yes your approach here seems to be correct. From what I understand your program should be similar to a expression matching program - one that checks for the proper use of paranthesis, box brackets, angular brackets, braces in an expression. If you are not familliar with such a program I … | |
Re: How are you going to arrange a list in 2D ? You would have to make a list of lists. With the first list just holding the heads of the list starting at that position. Something like this : |L1 -> List L1 follows... |L2 -> List L2 follows... |L3 … | |
Re: For everything that they can be used. Typically for taking user input from console. PS : Ignore this, masijade has given you the world !!!! | |
Re: How does the src directory contain a .class file ? That tells us that everything is [B][I]not[/I][/B] in the right place. On other thoughts, detail your problem if you want my solved threads count to go up, becuase I have a feeling I can solve this problem. It has all … | |
Re: This gives me the feeling that this code is not written by you, can you tell us why so ? | |
Re: You can go through the NetBeans [URL="http://www.netbeans.org/kb/"]tutorials[/URL], the one for handling images in GUI is [URL="http://www.netbeans.org/kb/docs/java/gui-image-display.html"]here[/URL] | |
Re: Post the code for [icode]binaryGenerator[/icode] method so that we would be able to run and chekc your code, what happens exactly. And yes BTW you are right about the do-while construct if it shows allocated as equal to c it should stop. | |
Re: [QUOTE]For the line, abstract1 cir = new child(); : Cannot find symbol symbol: constructor child() location: class child[/QUOTE] Here, you are creating a new [icode]child[/icode] instance alright, but there is no such constructor for the child class. [QUOTE]For the line ,child.child(side); : Cannot find symbol symbol: method child (int) location: … | |
Re: @nandomendonza : I would like to ask one question of you first. Have you been taught the for loop in the class (I assume you are in a class since you mention the word instruction) where you got this instruction. If yes, do you think it is so tough, after … | |
Re: Also if you are a beginner why use a fancy IDE at all ? Try coding by your hand using an editor, that would be better in the long run. Though some people use IDEs from the very beginning, it only results in you not knowing the language environment in … | |
Re: No we certainly won't [I][B]do it[/B][/I] for you. It's your work you have to do it. Also put code tags to your code if you want somebody to take a look at it. | |
Re: I don't know Robdale, haven't seen much of him either so i'll give him 2 | |
Re: To give you a start. Infix to Postfix expression problem is a typical example of problems that can be solved with a stack. Take a look [URL="http://scriptasylum.com/tutorials/infix_postfix/algorithms/infix-postfix/index.htm"]here[/URL] to get a better example. | |
Re: Post your code inside code tags. [noparse] [code=java] // code here [/code] [/noparse] | |
Re: Because you ask for a fancy way, I give it to you. So suppose you want to allow multiple answers without much work you can do this : [code=java] Scanner input = new Scanner(); String response = ""; System.out.println("Do you want to continue ?" Yes/Y/No/N); response = input.nextLine(); do{ // … | |
Re: Yes it is. I would have liked you to first having gone through the langauge documentation, since this is something that even the very first program requires you would have found this immediately and also learnt a few things with that. Search your question on the internet first if you … | |
Re: You say you have read a lot of theory, why then don't you consider practicing what you learnt in theory. Say for example try the Abstract Classes, Interfaces, Classes, Inner Classes, Exceptions, Threading etc in examples that you might have read in theory. This way you would also be asserting … | |
Re: [QUOTE=masijade;795755][url]http://www.javapuzzlers.com/[/url][/QUOTE] When you see puzzles that are far more complex than the one you seem to be in really helps you understand how trivial yours is. ;) Masijade has done enough from his side to solve yours. :D | |
Re: This is because your system is not able to locate java. Here you have two options : 1. Open a command prompt window. Then write set path=%[I]JAVA_HOME[/I]% where [I]JAVA_HOME[/I] should be your path to the bin directory in your java installation. So, say for example you have Java installed in … | |
![]() | Re: Assuming you know the index of the element to be converted do: [code=java] int anInt = Integer.parseInt(vector.get(index)); [/code] |
Re: take a look at the found1 variable, at first it is false, then when you enter a number that can be located in the array it becomes true [code=java] found1 = true; [/code] but then you do not set it to false again before checking for the second number. Then … | |
Re: [QUOTE=adventureen;792480]We understood your problem you con visit our site that is helpful for you Adventure travel is one of the fastest growing travel sectors. Our industry is undergoing a significant evolution to meet the increasing demands of clients and distributors of our products. for read more Click Here [SNIPPED] You … | |
Re: There is also a forum for JSP here. We would have liked you searching a bit and getting to know the place before posting directly. Moreover it's much more beneficial for you if you put this question there as you would get help faster. | |
Re: @praveenhai : Atleast care to take a look at the [URL="http://www.daniweb.com/forums/announcement9-2.html"]forum rules[/URL] for providing homework. How ever on earth can someone ask for a complete project. Do you think we have products ready to sell ? And if yes why should we offer our hardwork for free ? Commenting about … | |
Re: The same page where you got this code explains the questions you are asking: 1. If you want to start a process with the default working and without modification of the environment use this : [code=java] Process p = new ProcessBuilder("myCommand", "myArg").start(); [/code] where, myCommand = the command that starts … | |
Re: We are not the inventors of the reach algorithm why ask us ? And even if someone gives an answer why belive him when you yourself can check it out for yourself. Ask google I think he might be able to give you a better answer or atleast point to … | |
Re: Actually the decision whether to throw an exception should be made wisely. The reason the throw and throws concepts exists is that that when a programmer feels incapable of handling an exception himself then he can delegate the condition to the next higher level in hope that the caller of … | |
Re: [code=java] if(words.length <=3) [/code] This is wrong here, the length attribute would give you the length og the array, so for example if you have 5 words in the array, words.length will give you 5. Whereas you have to calculate the lenght of each word in the array. Here's how … | |
Re: @~s.o.s~ : I am afraid sos, but I do have a different opinion here, to prove my stance being correct here let me site you an example of another [URL="http://www.daniweb.com/forums/thread171147.html"]thread[/URL] here. If you go through this thread - I think you have already gone through - you would come across … | |
Re: What kind of errors are you looking for ? The spelling mistake you feel the IDE user has made could be variable declaration. Also since a user is free to name his variable anything, until he obeys the language rules for it, you cannot even compare English spellings. What most … | |
Re: Where exactly are you getting the problem and what is it. Also mention in a little detail what you want to achieve. | |
Re: There is not much common where purpose of usage is considered for Java and JavaScript though I am sure they share together much [URL="http://en.wikipedia.org/wiki/JavaScript"]history[/URL]. Java is a general purpose language for programming client or server side applications. JavaScript on the other hand is a client-side scripting language. Since you mention … | |
Re: That depends on your SMS Gateway which is also, in messaging terminology, called SMSC or Short Message Service Centre. If your provider uses the HTTP Protocol to have sms sent over to them then you would need to use HTTP POST/GET method. On the other hand if your provider uses … | |
Re: [QUOTE=Rashakil Fol;784695]That's what you get for using the worst programming language in popular use today :P[/QUOTE] But thats improper use rather than the language fault. Also are you a C guy. Nowadays many Java loyals are turning to Python, they seem to be of the same opinion. I know this … |
The End.