32,204 Topics
| |
[CODE]class hello { } class hello1 { public static void main(String aa[]) { hello ob[]={new hello(),new hello(),new hello()}; hello ob1[]=ob.clone(); // 1 } }[/CODE] ob is an array which is also treated as an object, and hence has a default clone method which is called at (1). But the default … | |
Hey guys, So, I need to add booleans on my project for the final piece. I have all of it done but the booleans. Basically, I checked about 10+ links on google, and none of them really explained how to do booleans. So, what I need is something that does … | |
Hey guys, I'm trying to create a program that has three items and adds the cost of the three items and prints the final total with sales tax. I need a subtotal, sales tax, and total amount. I'm having a problem getting the program to calculate the quantity correctly and … | |
i understand what the code does. but i dont understand a few lines: [CODE]package il.co; public class LinkedListEx2 { public static void main(String[] args) { LinkedList list=new LinkedList(); list.add(new Car("BMW", 150000)); list.add(new Car("SUBARU", 60000)); list.add(new Car("TOYOTA", 58000)); list.print(); } } class LinkedList{ private Unit head; public void add (Car data){ … | |
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * | |
Can somebody help me what to do to place tables in gui? | |
i m unable to interrpret my package from any other drive???? i mean ..i hav created my package, compiled it bt unable to run it... can anyone tl d way of running it or setting the path... the coding is done in command prompt | |
I know that it's a very undesireable scenario, but I need to create a database straight from java code. Yes, a database. Not a table. A database. The database will be dropped at the end of the program and will never be directly touched by the user, so all I'm … | |
Hi everyone, PLease help me out with permuation cipher, an example given to me shows a plain text as abcdef...up to z and ciphered text as fghijabcdevwxyzklmnopqrstu.. Im seeing some sort of a pattern with this text,Can you guys give an example java code to cipher of decipher using permutation … | |
can anyone suggst a link where i cud find the list of various packages and classes already defined in java library | |
I want a java program of ceaser cipher encryption and decryption technique. in which you have to take input(plain text) from input.txt file and encrypt it with program and save the output(cipher text) in output.txt file. again you have to take input from output(Cipher text) and apply decryption program and … | |
Actually i m doing constructor implementation.But i am new to java, can any tell what going on from line 11 to 14.I am having problem in understanding the bold in line 12 and line 13.Plz help..... 1. public class Animal { 2. String name; 3. Animal(String name) { 4. this.name … | |
[CODE]import java.awt.*; import java.awt.event.*; import java.awt.image.*; import java.io.*; import java.sql.*; public class RefHistTest { public static void main(String args[]) { int iw2, ih2; Image img2; int pixels2[]; double[] hist2 = new double[256]; int y; ResultSet r; try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); Connection c=DriverManager.getConnection("jdbc:odbc:CBIRS"); Statement st=c.createStatement(); r=st.executeQuery("select Images from ImageTable"); byte[] bytes=null; while(r.next()) … | |
can anyone provide with java code for performing text similarity calculation using cosine similarity. it is a part of my project.. the context is a pair of records P12 = {r1,r2} , where r1 and r2 can come from same or different data sources, as a similarity vector V12 = … | |
Hello, I am a new bee in developing large java projects so need your help in this regard. As a part of our project we need to upload a image to a site(say picasa) or any photo sharing site. I would like to know whether it is possible to retrieve … | |
The timer is not working perfectly. it gives a very off estimate of the elapsedtime each time. Please Help [code] import javax.swing.*; import javax.swing.border.*; import java.awt.*; import java.awt.event.*; import java.util.Random; public class JumpingPanel extends JFrame{ public static final int BUTTON_WIDTH = 45; public static final int BUTTON_HEIGHT = 45; static … | |
[TEX]. . . i need some tips on programming java with looping structure, tnx . . .[/TEX] | |
Can someone help me solve this! thx Conditional structure , include also the console result. 1. Using switch case design and write a java application that takes as input a single letter and displays the corresponding digit on a telephone. The letters and digits on a telephone are grouped this … | |
Hello Members, I am trying to multiply two matrices using multithreading. I get a NullPointerException on the line that is commented in Bold. Following is the entire code. Any input is much appreciated. [CODE]import java.lang.*; import java.io.*; public class Matrix_Mult extends Thread { static int a[][]; static int b[][]; static … | |
Hi everyone I have a project that I have created in Netbeans. I would like to deploy it as a JAR file, so i have "build"'ed it and I have a jar which runs nicely in the /dist folder. Problem is, the program in question requires reading from and writing … | |
I have 22 errors for cannot find symbol.....Please help! [CODE] import javax.swing.*; //needed for swing classes import java.awt.event.*; // needed for the action listener import java.awt.*; //needed for the boader layout class import java.io.*; //need for the file and IOException import java.util.Scanner; // needed for the scanner class import java.util.List; … | |
Hello, everyone! I am unable to start a OSGI bundle. I'm using Apache Felix and this is my bundle: 1) Activator.java [code=java] package Example2; import java.util.Properties; import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; import Example2.Service.IDictionaryService; /** * This is the bundle. * @author Pierre-Alexandre * */ public class Activator implements BundleActivator { public … | |
Just a begginner question Object x = new Object(); System.out.println(x); everytime i get sthg. 16:18:35,222 INFO [STDOUT] --java.lang.Object@adfaec 16:19:26,937 INFO [STDOUT] --java.lang.Object@181db77 16:21:34,538 INFO [STDOUT] --java.lang.Object@14e5e21 what is the thing being printed? the object memory place? please help a beginner | |
I designed to look like that picture click here: [url]http://i195.photobucket.com/albums/z285/boiishuvo/eg.jpg[/url] But I got two errors shown below: Pizza.java:150: cannot find symbol symbol : constructor Labels(java.lang.String) location: class Labels localJPanel5.add("North", new Labels("PIZZA")); ^ Pizza.java:187: cannot find symbol symbol : constructor Labels(java.lang.String) location: class Labels localJPanel12.add(new Labels("PRICE")); ^ Can anyone fix that … | |
Am developing an accounting system for my end year project. I intend it to be able to generate weekly report for sales. Is there any inbuilt java fuction for this@? | |
When we use File.getAbsolutePath() we get the path of file as C:\BlahBlah\Blah.txt. But I want the path name as C:/BlahBlah/Blah.txt i.e instead of backward slash "\" i want a forward slash "/" in the path. How to get this. I tried to create a parsefile method. [CODE] public String parsePath(String … | |
Hi, I wanted to created a java file base on the given javadoc below. I am currently stuck on the embezzle method. First, i don't understand what's the "BankAccount" in 'public void embezzle(BankAccount other)' do or is. Second, How can i add funds from the other account to the other … | |
please any professional out there can suggest me with project ideas . . for my final year project work . . plz. .plz. . | |
I'm new to java , i've tried to make simple jdbc application . I can store a value in database and also can retrieve it but only in console window. i've got the variable String name in package db, and what should i do to display the value of that … |
The End.