masijade commented: Thanks. Just a wild hair I guess. +11
Salem commented: Well said +26
Educational value might be be zero but think about E for Entertainment, that's gauranteed !!!
kung pwde k mgbisaya ok lng, pasabta lng ko sa T[] ug OldT[] ug nganong k2ng sa Fig 1.13 (page 35) sa JEDI course notes dili masabtan :(
Did you just swallow an ostrich size fly ?
I did not understand the point of your earlier post nor am I able to understand it now. Your earlier post was sort of making ground for future questions that you might have, sort of preparing us for the questions you might throw at us. But I suppose there was no need of that, since many people here have been doing the same since they joined in, they do not to be "prepared" as such. Your this post too is of no use, if you are not posting any questions for a long time does mean that you have been pretty busy doing whatever you want to, there's no need to post saying that you have been busy enough and that you do not have any problems, well we have been busy enough too in our work, no one's sitting here idle waiting for questions that you have promised might come four months ago.
Knowing here the purpose for such a random number would be important before advising you of anything. Also Java has a UUID Class that generates Universally Unique Identifiers. This class has methods to generate four different types of UUIDs one of which is to generate a pseudo random number, go through class javadocs go get an idea.
No I don't think so. Since your application connects the database server it would need the database server running, whenever it's invoked on the client machine. This won't be true in your case since you run the server inside your NetBeans IDE.
Firstly you did not mention any topic apart from Java GUI, which is far too generic to be a topic at all, secondly if you are voluntarily competing in the camp don't ask us to submit code for you. Do it on your own and show it to us and ask specific questions. For ideas you can search this forum for answers to other such similar questions so do the good work on your own. Also the next time you post I would appreciate a more specific thread topic than "I would like to ask". no one really started a thread here with an answer.
hello...i am confused,,it is possible that a linkedstack will be full??i only implement a method that isEmpty(),,and it reads the method if the stack is empty..but if the stack is full, it do not even read the method i made....would someone help me?/,,,thank you ahead...
If you know what a "linked" list is, and I suppose you ought to know that if you are implementing a stack with it, what does common sense tell you ?
Then the query given by me should work with modifications wherever you want to have them.
Okay guys. I'm sorry. I'll try to control myself. Something about this thread just brought out the worst in me, I guess. ;-)
I'm afraid I don't feel so. I think it brought out the wickedly funny side of you and it certainly gave us a good laugh following this thread with your posts. Thats the reason I said you seem to be in top nick ;)
While specifying the foreign key constraint you have specified "ON UPDATE NO ACTION" while this seems to mean that no action would be taken on update, it specifically means that you will not be allowed to update too, either remove the clause or if it is binding for you to have it, modify it suitably.
Duplicates meaning, the entire name should be identical or just any of the first name, last name etc ?
Check "select firstname, count(first name) from tablename having count(firstname) > 1" something like this.
god almighty, has your keyboard lost all the letter inscribings on it or what ?
Anyways, go look for some project ideas youself.
masijade looks to be in top nick !!!
Half of the world already knows it, so whats the point announcing it, especially here which is a forum to ask questions and not some web notice board.
In Java there are Classes, Abstract Classes and Interfaces.
Classes and Abstract Classes can be inherited, but a Class cannot inherit from more than one Class or Abstract class. Abstract Classes cannot be instantiated, though as mentioned above they can be subclassed.
Interfaces on the other hand are implemented, a class can implement multiple interfaces.
I suggest you go through the Code Conventions document as published by Sun. This document is already sited in the "Starting Java" thread at the start of this forum.
Would you mind putting your code directly here in code tags ?
No I guess here the problem is not with the name or the integer stuff in the call parameter. What you were doing when calling with the parameter number is this : cstmt.setInt(1,100);
which according to code should have been this cstmt.setInt(2,100);
I guess if you try this you would be able to sort that out. Just try it.
On pondering over it now, I feel, even I might have misinterpreted, cause this 4 bytes thing didn't cross my mind, I was of the notion that he wanted the integer value of each of them. Well, nevermind, the OP has both the solutions, he can choose the appropriate one. Cheers !!
Did you happen to read the above posts ? Did you try out the things mentioned there ? Did you go through the links ? Those may help you in eradicating your problem. Have you really 'tried' to help yourself ?
No, there are a few shortcomings in this piece of code.
public String VoorNaam()
{
return VoorNaam;
}
public String AchterNaam()
{
return AchterNaam;
}
You have defined two methods of the same name as that of the variables, they should be called getVoorNaam()
and getAchterNaam()
since it is the getter action that they perform.
Array of Byte
means
Byte [] byteArray = new Byte [5];
I don't know how else to explain, but this certainly was picked up by the original poster since he asked me the next question on that, which told us he wanted to convert the bytes to integer manually. My response to this post "then you need to write your own binary to decimal function" explains the next step without going into unecesary details, which as I mentioned should be left to the OP to be figured out.
To say the least your requirements are very vague. If you have been given the base pointer address calculation as according to the formula, how can you be implementing the stack as a list ? If your base pointer address calculation is to be taken into consideration then your stacks should be in an array with their base pointers at the calculated locations of the array. Also the Multiple stack definition as read by me on the internet specifies that these are implemented in an array where say there are two stacks then these have base pointers at the opposite ends of the array and they grow towards each other.
How have you been asked to implement these in a List, detail on that.
Also to answer your question on setting tops you can set them to the base pointers while setting the base pointers themselves. Why, can't you ?
To elaborate on my previous post further, if the result of the expression in the if
stucture is of the type Boolean
it is converted to boolean
by using the method booleanValue
of the Boolean
class. These conversions are called Unboxing Conversions You can read more about them here
Having said all this, if the point mentioned by me is not what is causing the problem in your case then I suggest, you let us know (and know yourself, very clearly) what is that that you are comparing. There are certain things that you as the implementor need to be careful while using compareTo
. These things are mentioned in the javadocs for compareTo
I think, though I am not 100% sure, that the problem is rooted in the if (objects[min].compareTo(objects[scan]))
statement over here. compareTo()
returns either 1,0,-1 depending on whether the calling object is greater than, equal to or less than the object passed as a parameter.
According to the above statement you seem to be of the notion here that if(1)
would make the control move into the if condition. But I don't think if(1) would be good enough, according to The Java Language Specification the if()
structure requires the expression to result in a boolean type, else it gives a compile-time error. Is your program compiling correctly? even if it is I suggest you get the if(1) structure confirmed.
1. Use code tags to post code.
2. Instead of asking of us whether your code is ok or not you can check it yourself, if it does what it is intended to do you know what it is, whether it doesn't you still know what it is. Why do you need our approval.
@~s.o.s~ said : If the given character is not a parenthesis or bracket, move over to the next one
3. doesn't this pretty much explain what you got o do when there are no paranthesis at all ? You just keep on moving over all the characters till the end of the expression.
I said the same thing, the only thing is I left the logic part for him to figure out, and I feel thats what was supposed to be done.
hey congrats man, good to hear that, you might be the youngest, but as I said in my earlier post don't worry too much about that.
I am 26 with no SCJA in front of my name so for me it's far far better. ;-)
Show us some effort from your side first, how would you go about implementing such a project we would like to know that first. Then you could maybe ask us specific questions than "Please send me some algorithm", and we would be glad to help you.
Also I would like to ask another statistical question here wile this is going : Anyone knows the youngest person to get an SCJP coupon and then did not get time enough to prepare for it while the coupon expired ?" Well I was 25 when that happened to me.
Alright curiosity is one reason, but beyond that I would like to know the point of such question not that I am against asking of it or something like that, but I just want to know the reason.
Is it that you have already got the certificate and want to whether you are the youngest in doing so, if yes, I would rather tell you "don't worry mate, you have alreayd done good , don't worry whether you are the youngest in doing so". If not that, and if you are planning to get the certificate and want to know whether you'd be the youngest to do it, I suggest you should do it anyways, it won't harm you even if you are the oldest person doing it.
Just expressing my views here.
how about a project to convert not so good written language to a very good one (that corrects grammar as well and adds if there is none) ;-)
you ask for challenging projects when you are not even ready to accept the challenge of brewing an idea in your head for the same. Tell me frankly, is it so difficult ?
then you will have to use your own binary to decimal function and pass it the byte value.
Yes you can accept a string as an input and then convert this string to a File
type. There is a contructor in the File that allows this.
public class DeleteFile{
public static void main(String [] args){
// Pass the first argument which is a filename to the constructor.
File deleteFile = new File(args[0]);
// code to delete file goes here.
}
}
But remember the path you specify on the command line should either be an absolute path or you should be running the program from the same directory, where the file/directory to be deleted exists, for this to work.
EDIT : We would certainly like you doing some homework of your own, it seems you haven't gone through the File
class documentation at all.
If you have an array of Byte()
class, then the class itself has an intValue()
method that returns the value of this Byte as an int.
Read the javadocs for the Byte class for more details.
I agree with jasimp, but I guess if your requirement is just to monitor network traffic or protocol analysis, there is already a product that does that for you.
Wireshark is a s/w that is used for network protocol analysis. Check if thats what you want.
>parameter which has default value must be the last one in the param list
No not necessarily, if your first argument is default in the procedure just put a ',' without specifying any '?'
proc = con.prepareCall("{call sp_SPNAME (,?) }");
This code works for MS-SQL, but you are using Oracle and since the SQL Syntax can be vendor specific you will have to check.
// Here this code shows two parameters being passed to the sp
// Here con = connection,proc = CallableStatement
proc = con.prepareCall("{call sp_SPNAME (?,?) }");
proc.setString(1, var1);
proc.setString(2, var2);
proc.execute();
// Now if one of the parameters has a default value all you need to do is, remove one of the '?' and pass just one parameter.
proc = con.prepareCall("{call spSPNAME (?) }");
proc.setString(1, var1);
proc.execute();
Also you need to take care in the SP, to insert just this one parameter correctly and you do not need to insert the other one since as you say it is default.
private JRadioButton male;
private JRadioButton female;
private ButtonGroup gender;
// create the radiobuttons
male = new JRadioButton();
female = new JRadioButton();
gender = new ButtonGroup();
// set the necessary parameters for the radio buttons
male.setText("M");
male.setSelected(true);
female.setText("F");
female.setSelected(false);
/*
*can be used to catch the button on which the event is generated * (by checking the action commad)
*/
male.setActionCommand("Male");
female.setActionCommand("Female");
// finally add the two buttons to the 'gender group'
gender.add(male);
gender.add(female);
please help
any body knows the code in java networking..i want the code of transfer folder contents from client to server.....thread must me included so that timely back up will occur...<snipped email>
Read the rules to be obeyed by members while posting on this forum. Try and respect them. Also we won't give you the code out right, show us some effort from your side and then ask questions where you get stuck.
Note : People on this forum don't get paid for the help they provide you, so basically they are taking time out from their task that wins them their daily bread to help guys like you, so I think you understand we are not sitting here ready to take instructions and provide the code for you.
The same way you would do in a console java program, the java syntax for writing the BFS won't change for certain. ;-)
Only time when you need to access some local resources would the applet have restrictive behaviour. But for trees which I assume would be entirely in memory I don't think there would be any restrictions even if you are writing it in an applet.
Have you Googled it already ? If not it would be worthwhile doing it. BTW a google search for "tidalwave java package" lists only ine such : 'it.tidalwave' Is it the one you are looking for ? If not specify the full package name. Do the same for the other package (Google it)
In your previous post you gave a formula to calculate the array of base pointers which will all be holding the start of the m stacks.
B = ën/mû * i - 1, 0 £ i < m
Here,
n is the size of the array
mu - I guess is the mathematical constant, though I don't know how it fits over here.
i = the stack number, out of the m stacks that you want to calculate the base pointer location for.
For the m th stack the location is given by you as follows :
B[m] = n-1
I hope this clears it up.
A DBMS in Java ? Bravo !!!
This thread will offer you a whole lot of information about starting java. But to write your own DBMS in a langauge I guess you will have to look far beyond a particular "link" or site. This will need in-depth knowledge and understanding not to mention much experience in the langauge to be achieved.
If that solves the question in your mind, and you do not have any further questions related to this, mark this thread as solved.