32,204 Topics

Member Avatar for
Member Avatar for tsegaighere

Hey guys!!!I am a senior majoring in computing science and I was wondering If u have some ideas for my final year project which I plan to do in JAVA!!I was thinking of animating sth but I cant see how practical JAVA is for that!!! ANY IDEAS?????

Member Avatar for rotten69
0
334
Member Avatar for joshmo

hello. I would like to know how I can make out a Java code from a given mathematical equation like differentiation equations, summation and integration

Member Avatar for JamesCherrill
1
1K
Member Avatar for utchia

hi i have been working on my project to create a store and i have to add items and sell items, and once i add items i store them into a textfile separated by commas, and i made the add item button work perfectly but i am having trouble with …

Member Avatar for Majestics
0
577
Member Avatar for Atlanta15Braves

I need to sort these strings in order and I have changed the code of my program which use to sort integers and now I need it to sort strings and I cannot get it to work, any help..... import java.util.Scanner; public class Strings { // -------------------------------------------- // Reads in …

Member Avatar for subramanya.vl
0
216
Member Avatar for Neversleepin

Hi everyone, i want to set input verifier for a jspinner when the user click a value and if the value is out of range (0 to 10) it must display a message like "Please enter a value between 0 to 10" and it must validate until the correct value …

0
159
Member Avatar for XodoX

Hello, I'm looking for a CSV parser and I found this example.... package com.ibm.ccd.api.samplecode.parser; import java.io.BufferedReader; import java.io.StringReader; import java.util.ArrayList; public class CSVParser { String oneRes; private String line = ""; private int nbLines = 0; private BufferedReader reader; public CSVParser(BufferedReader reader) { this.reader = reader; } public String[] splitLine() …

Member Avatar for Taywin
0
129
Member Avatar for charles.darwin

Hi guys. im writing a program to check an input string (a password) for its level of security (strong, medium, weak). here is my code for the method: public static int passwordType(String password) { //0weak, 1medium, 2strong int hasSix = 0; int upper = 0; int lower = 0; int …

Member Avatar for charles.darwin
0
156
Member Avatar for rachelmorg

hey this sounds like a really simple question to me but I can't seem to figure out how to do it! My code so far is public class numbers { public static void main(String[] args) { final int N = (args.length); for (int i = 0; i < N; i++) …

Member Avatar for rachelmorg
0
3K
Member Avatar for arcticman452

My program compiles but when I fun it I cannot get the city from the JComboBox to show in my JOptionPane. It shows up as "null" and when I click the clear button, nothing happens. I'm not sure how to fix these two problems. Here is my code: import java.io.*; …

Member Avatar for radhakrishna.p
0
160
Member Avatar for java123456

hey guys so i am having a problem in my assinghmnet . i am making a text file and it has to import to java and make a table from the text file . so there is what the txt file looks. 3 // this should be the rows 1,2,3, …

Member Avatar for subramanya.vl
0
260
Member Avatar for nseeley3

Hey everyone! So I want to make a simple console based chat client as my first java project (ambitious I know) so here is what I have brain stormed as to What this program will entail (Let me know if I missed anything. * Cases (to handle arguments such as …

Member Avatar for subramanya.vl
0
242
Member Avatar for jsp418

Hi. I'm writing a program that reads information from three seperate classes. public class Animal { protected int id,animalTotal; protected String type; protected double mass; //------------------------------------------------------------------------ // Sets up an animal with the specified ID number, type and weight. //------------------------------------------------------------------------ public Animal (int animalID, String animalType, double weight) { id …

Member Avatar for subramanya.vl
0
204
Member Avatar for nickcolb

So I'm working on a small calculator applet and whenever a button is pressed (generating an action event) i get this: Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException. Something about a missing source? The variable m is an instance of my myFunctions class which houses all the necessary formulas. I believe the …

Member Avatar for radhakrishna.p
0
221
Member Avatar for Violet_82

Hi there, I am trying to find an explanation for what the `findWithinHorizon()` does. I landed on this page http://docs.oracle.com/javase/7/docs/api/ and I know that the method is part of the `java.util.Scanner` class (isn't it?). How do I find it in the page above please? thanks

Member Avatar for Violet_82
0
245
Member Avatar for aabbccbryanmark

package prjarrays; import java.io.*; import java.util.Arrays; import java.util.Collections; class BubbleSorting { public static void main(String[] args)throws IOException { BufferedReader a = new BufferedReader(new InputStreamReader(System.in)); int []num = {54,92,04,98}; -> Arrays.sort(num, Collections.reverseOrder()); for(int str : num) { System.out.print(str + " "); } } } > cannot find symbol method sort(int[],java.util.Comparator<java.lang.Object>) why …

Member Avatar for Ezzaral
0
130
Member Avatar for LdaXy

i'm writing a text based game that creates a world based on the data inside of the specified file. however, the code i have won't let me use the function DataInputStream.ReadFully(byte[]b) Code: package textgame; import java.io.DataInputStream; import java.io.FileInputStream; import java.io.IOException; import java.util.Stack; public class world { Stack<String> LevelData = new …

Member Avatar for stultuske
0
1K
Member Avatar for slimergan

Hi,I wish to simulate a traffic flow for a roundabout with 3 exits and be able to change how many cars enter and exit the roundabout and randomly turn off the exits. At a later stage I would also like to be able to input traffic lights to see would …

Member Avatar for JamesCherrill
0
99
Member Avatar for MistaGeorge

So this more than likely has a simple answer, but i cant seem to find it. I have a 2d array in one class, what I want to do is get this array into my other three classes. Now I'm not sure but I believe I have to use inheritance, …

Member Avatar for NP-complete
0
129
Member Avatar for jinxmc

import java.util.ArrayList; import java.util.Iterator; import java.util.LinkedHashMap; class oldEmployee { public static final int length = 0; static int empid[]={1,2}; static String Name[]={"name1",name2}; static String State[]={"state1","state2"}; static String City[]={"city1","city2"};; static String Area[]={"area1","area2"}; public Employee(int empid,String Name,String State,String City,String Area) { this.empid=empid; this.Name=Name; this.State=State; this.City=City; this.Area=Area; } public int getEmpId() { return …

Member Avatar for stultuske
0
204
Member Avatar for Atlanta15Braves

I am trying to switch the below code to sort in descending order rather than ascending. It works when counting upwards, but nothing I try helps with getting it to count starting with the largest number and count downward. public static void insertionSort(Comparable[] list) { for (int index = 1; …

Member Avatar for ~s.o.s~
0
750
Member Avatar for DEAD TERMINATOR

I'm trying to create a program that will draw an equilateral triangle with an oval at the center point when the mouse is pressed, and while the mouse is being dragged, the triangle will redraw itself so that the triangle remains equilateral regardless of where the mouse is (the mouse …

Member Avatar for DEAD TERMINATOR
0
319
Member Avatar for TheMrPatrick

Hi, I am currently making an assignment for JAVA, but I get stuck at the following. I need to make a simulation of a shop where a customer puts objects in his "basket" and with that basket you go to the checkout counter. Now we have to make it possible …

Member Avatar for NP-complete
0
561
Member Avatar for Nandomo

I have this assignment for my java class, it runs fine, but the professor wants us to incorporate a private gradeExam method, which I don't know how it work fit, since I cannot call it from the DriverTest class which contains my main. package project6; /* A demonstration of how …

Member Avatar for Nandomo
0
198
Member Avatar for shaneos

I posted this somewhere else but I think it was deleted so I'll post it as a new question... Here's my problem; I've been developing a packet sniffer using the Jpcap library from http://netresearch.ics.uci.edu/ . I was developing using the windows version of the java library, but now I realize …

Member Avatar for shaneos
0
492
Member Avatar for sania khan

Is it possible to get location in form of text through Google map using Android java?

0
63
Member Avatar for Violet_82

Hi there, as one of my first programs in java, I thought I will do a simple (!) lottery program...needless to say it doesn't compile, and after looking at it for quite awhile trying to unsuccessfully spot the error (I am not sure how to debug in netbeans, any advice …

Member Avatar for Violet_82
0
13K
Member Avatar for asif49

Hello, My problem is that I have a class, which needs to extend either one of two classes - the one it should extend depends on some value that is determined during runtime. I understand that there isn't a concept of having an if (this condition) extend thisclass else extend …

Member Avatar for stultuske
0
89
Member Avatar for nvijay
Member Avatar for stultuske
0
154
Member Avatar for myadav

Hi All... I am new to java, I am facing problem... Problem: 1) I want to create a ArrayList <String> and add Strings into it. problem: 2) I want to compare two Array List elements . their size and contents (strings type) which may be stored in any order. For …

Member Avatar for myadav
0
366
Member Avatar for arcticman452

I have the main part of my code done but I don'T know if I should use an action listener or an event listener for my JComboBox. I have 4 JComboBoxes and only need to retrieve the info from my vehicleBox and fuelBox at this point. I need to take …

Member Avatar for jalpesh_007
0
200

The End.