32,199 Topics
| |
I need to create a function that returns a number with the amount of characters in common among one string and a vector of them. [CODE]public int sameChars (Vector<String> otherStrs){ int result = 0; String original = "aab"; for (int i=0; i< original.length(); i++) { char aux = original.charAt(i); String … | |
Hi guys, I demand to know the correct order of the following topics to study [COLOR="Green"]Object Oriented Design and Analysis[/COLOR], [COLOR="Red"]Design Patterns[/COLOR], and [COLOR="Green"]UML[/COLOR] Thanks in advance [EL-Prince] | |
Hi to everyone. I'm a beginner at Java and I'm studying a software develoopment course right now. I have a problem with my first assignment. In particular with the last exercise of the assignment that is about writing a program that shows a character distribution with a counter that shows … | |
i wttched a pdf file can you open and c it please help me and solve this assignment..... please i want it neccessary.... | |
Hello, have a good day. please help me to read large amount of data from secondary storage device in java very quickly..............pls.......pls........ls..........s........ | |
i need to print stars on console like this * * * * * * * * * $ $ $ $ $ $ * * $ $ $ $ $ $ * * $ $ $ $ $ $ * * $ $ $ $ $ $ * * … | |
Hi , Can any one tell me differences between Statement ,Prepared statement,CallableStatement and when to use which (Clear Idea) | |
Hi, I have an assignment requiring me to use the printStringArray method, but I can't find any examples on how to do so in my textbook or on the web. Can anyone provide an example please? I'd be very greatful! | |
I have a toolbar and various buttons in. There is always a dashed line displyad along the borders on last button clicked. Aslo there are some sliders in my panel. When I try to adjust the value of a slider it also has a dashed border. This border is only … | |
Hello. I need to write a static recursive method that returns the frequency of occurrence a particular digit d in an integer n. For example, if passed (1342457,4) it should return 2, whereas when passed (1342457,6) it should return 0. I won't put my code in as it is arbitrary, … | |
I can't figure out what's wrong - I was remaking the code from an older and messier version, but now I've hit a roadblock because what I say in the actionPerformed section just doesn't happen. I suspect that it's because of the Timer, which a friend adviced me to link … | |
I cant get "\nNet Pay: " + netPay(dGrossPay, dRetirement)); to display anything other than 0.0. I know I need to assign a value to dGrossPay but im not sure how to. [CODE] public int menu() { Scanner keyboard = new Scanner(System.in); String strUserName; double dHours; double dRate; double dGross = … | |
Hi, When I convert a String value to float by using Float.valueOf(String), The return value is not containing last decimal. Ex: String a = 2.50; float b = Float.valueOf(a); Now the float "b" is holding only upto 2.5. It is not converting String value to float properly. My requirement is … | |
Hi everyone, I'm trying to write a code that converts the number that a user inputs to either Celsius or Fahrenheit simply by pressing a button. So far I was able to compile and run the program displaying the panel, buttons, and the text field but I'm not sure how … | |
Why is this an illegal start on an expression? public Account consolidate(Account accnt1, Account accnt2) In my if statement It says name has private access in account. What does that mean and how do i fix it? if((accnt1.name).equals(accnt2.name)) [CODE]//*********************************************************** // TestConsolidation // A simple program to test the numAccts method … | |
hey everyone, I have a quick question, and appretiate any help given, I need to check if my Javadoc is correct or not, I have this assignment due, but don't know if there would be a javadoc comment for the "boolean" I added a javadoc comment to check with you … | |
I have this build method for my expression tree. I want to build it in infix but its not coming out correctly. So, I was wondering if anyone can help me. Thanks. [code]private TreeNode build(Scanner input) { boolean leaf; String token; int value; TreeNode node; leaf = input.hasNextInt(); if (leaf) … | |
Hi, how to create trigger in mysql 5 with java. i have code like this, but still error " java.sql.SQLException: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DELIMITER $$ CREATE TRIGGER `a1`.`xData` … | |
Hi all, UDATE: Let's not hastily rush into this. I may have found my problem. BTW, my result set is populated with all of the required data. I have a custom renderer which renders table cell values from a query. The result data is populated into a 2 dimensional array. … | |
I have got a problem with the layouts. I am creating a Grouplayout for my JLabels / Buttons etc in a window .. Then I am adding a Jtable using the JFileChooser for which I am specifying GridBagLayout and then adding the layout to Jframe again after JFilechooser creates a … | |
Hi Everyone... I need to convert a JFRAME to an APPLET can I do that by simply extending the JApplet Class and replacing the main method with start ? I've tried this and my program will compile but wont run Here Is the Original Code [CODE] import javax.swing.*; import java.awt.*; … | |
I am trying to send an EXCEPTION from a Web Server to a Client using JAX-WS ... When the exception is thrown by the server the client does catch it ... but the contents are not the expected message... [Code] [Server.java] package pck; @WebService() public class Server { @WebMethod() public … | |
Hi, I am trying to get the max number from an array, but I'm not sure how to tackle it. This is what I have so far. [CODE]import javax.swing.*; public class InitArray { public static void main( String args[] ) { int array[] = { 69, 23, 47, 81, 92, … | |
[code]List result = q.list(); if (result.isEmpty()){ System.out.println("No Projects"); } else{ for(Object object : result){ Project p = (Project) object; System.out.println(p.getName()+" worked on by "+p.getEmployees().getName()); } }[/code] [Quote] error : CompanyReports.java:303: cannot find symbol symbol : method getName() location: interface java.util.List<Employee> System.out.println(p.getName()+" worked on by "+p.getEmployees().getName()); ^ 1 error[/Quote] Can anyone … | |
import java.util.*; public class MainAssignment3 { public static void main(String[]args) { int Max =0; int Value =0; LinkedList<Integer>Input=new LinkedList<Integer>(); LinkedList<Integer>Temp=new LinkedList<Integer>(); LinkedList<Integer>OutPut=new LinkedList<Integer>(); Input.addLast(90); Input.addLast(21); Input.addLast(33); Input.addLast(80); Input.addLast(67); System.out.println("The Input Stack is : " + Input); while(!Input.isEmpty()) { Max = (Integer)Input.removeLast(); Value = (Integer)Input.removeLast(); System.out.println("MAx: " +Max); System.out.println("Value: " +Value); … | |
hej I need to Construct a loan account for a small company this is the info that is givin * You can borrow a maximum of 1,000,000 kr • There shall be no redemption. The entire loan amount + accrued interest payable in one sum at the end of the … | |
I'm a student, now i'm developing a pc application using which require to access the net for sending SMSes.My code uses http connection to way2sms site for this.I could send SMSes from it when the code is opened in JCreator.But when using Eclipse it shows an error "java.net.SocketException: Permission denied: … | |
[CODE] import java.util.Scanner; public class primenumbertest { public boolean isPrime(int num){ int x; Scanner input = new Scanner(System.in); System.out.print("Enter a number to find out if it's prime or not (greater than 1): "); num = input.nextInt(); if (num == 2) return true; // check for divisible by all even number … | |
Hello, How can I change font style of ToolTipText and Dialog's text in java application program?Pls help me.Thank in advance. | |
Hi, I am trying Serial Port Communication in Linux using Javacomm API and RxTx. I'm configured RxTx as per the documentation. But I received an error as follows, Exception in thread "main" java.lang.UnsatisfiedLinkError:com.sun.comm.SunrayInfo.isSessionActive()Z. Would you help me please.. |
The End.