32,199 Topics
| |
Hello, I've been trying to read txt from a file, and breaking each line into words and storing them in Array. Example. txt file C001 John Smith 999999 C002 Mary Agnes 888888 Here is my code. public class Customer implements iCommand{ static List<Customer> cust = new ArrayList<Customer>(); static private String … | |
I am thinking to develop a program/software to simulate autonomous driving car (artificial intelligent agent) using java. A car(agent) will move forward avoiding the obstacle in the dynamic environment. How do i start? | |
I need my running java application to be able to detect a web address that is typed into any browser's address bar. This is because I need it to make a decision depending on which website is typed into the bar. It would be best if I can rather get … | |
how to write a pseudo-code for telling someone how old they will be in 15 years to come | |
Getting errors in my java program.Please retify my program errors,Explain the mistakes? class Cine { double t=70.00; String i="CINEPOLIS"; String j="HAPPY"; { public void worldCine(); { System.out.println("Ticket rate:" +t); } public void worldCine1(); { System.out.println("Theatre name:" +i); } public void worldCine2(); { System.out.println("Movie name:" +j); } } public static void … | |
Yes, I am new to Java as you will see from my post. I have done most of the work therefore; I am not interested in someone to doing my work for me rather I am looking for a new set of eyes. My program is to keep track of … | |
Hello, team. When I run my program it is not allowing me to run this program. Looking to the professionals for some help. Tester import java.util.Scanner; public class ProductTester //the class ProductTester { public static void main( String[] args, Object getPrice) //the main statement { Scanner user_input = new Scanner( … | |
Hi All, Interfaces cannot be instantiated. Could you please explain why the following is valid: interface MyInterface{} MyInterface[] myInterface = new MyInterface[]{"a", "b"}; Cheers! | |
I tried dreamincode but the mods there are pretty mean so i have come here to humbly beg for help. First off let me start by saying I'm a new programmer and I am frustrated and cofused by the class i'm in prg 420. I need to pass this assignemn … | |
Hey there everyone, I have been a computer programming instructor for several years now. I like helping my students, but every year, they are the same age, and have generally the same skill set. So yes, I'm getting bored: it just feels like doing the same thing year in year … | |
Hi there I have a problem which I would like to get solved. I am making a ultra modded survival server (a minecraft modpack) and I have created the whole server but I still have one problem, biomes o plenty is not working. I have the server.properties level-type set to … | |
Right now I'm having a problem getting my program to run, it compiles with no errors. The only previous error I had was that it stated reached end of file while parsing which I think I fixed. Can anyone help me? import java.util.Scanner; public class Payyroll2 { public static void … | |
Hi i need help with the code ive done in java, iv got a project im doing and i get this when i run my program. --------------------Configuration: <Default>-------------------- Usage: java [-options] class [args...] or java [-options] -jar jarfile [args...] (to execute a jar file) where options include: -d32 use a … | |
Hi! I'm having hard time where to put the system.out.print code in my assignment. please check my codes, I'm still new and learning in java sorry If I have mistakes :) here: import java.util.Scanner; public class SelectionSort { public static void main(String[] args) { Scanner input = new Scanner(System.in); System.out.println("Enter … | |
Hello, I mainly wanted some tips and advice on ways to optimize this code, it's actually an exercise from my class' power point file. It says: Exercise 1 Sam and Ella's Delicatessen wants you to write a program to take orders from the Internet. Your program asks for the item, … | |
Hey guys, I made the game Rock Paper Scissors where 2 players can play against each other. Here is my client's GUI ( The server doesn't need 1) and I was wondering what else to do to make it better looking/more "advanced". Any feedback is appreciated - The entire GUI … | |
In a 4 player network big 2 card game. how do I track a player turn? so in my program, my server will wait for 4 clients to login. my server will spawn a new thread each time a client is connected after 4 clients have log in, the server … | |
This is a contiunation of https://www.daniweb.com/software-development/java/threads/484036/java-network-game-keeping-track-of-a-player-turn# Right now my server will read for incoming connections from the clients. if it reaches 3, it will break off from the while loop and any more clients connected after that will be refused. I set the first player by doing this. game.currentThread = … | |
I have multiple embedded database that all work fine while running inside netbeans, but when running the program outside (stand alone) of netbeans one of the databases does exist ie the error java.sql.SQLSytaxErrorEception: Table/View'RACE_DATABASE' does not exist. The database is confirmed as embedded when checking its properties. this was working … | |
using: eclipse I have created a android app and I am trying to add some ads on to it. I am using admob.com but I am not sure what I am doing wrong. First here is error I am getting: #------- #ERROR: #------- 08-27 23:09:03.650: E/AndroidRuntime(26340): FATAL EXCEPTION: main 08-27 … | |
i ecounter problem again, this time different, i've success compile my project from.java to .jar then compile .jar to .exe, then i have try my .exe result, so at first was working well, but when need connection to database, that was appear notification connection failed .. thats all my problem.. … | |
what should do? if show() replace with setVisible(True) then.. getText() replace with ? addItem() replace with ? | |
when i was compile with -Xlint: unchecked then got some warning like this Compiling 12 source files to C:\Users\Titus\Documents\NetBeansProjects\SITA\build\classes warning: [unchecked] unchecked call to addItem(E) as a member of the raw type JComboBox what should i do? | |
i had use combo box like this {jComboBox2.addItem("-- pilih menu --"); try { String sql = "select * from iomenu"; Statement cn = con.createStatement(); ResultSet rs = cn.executeQuery(sql); while (rs.next()) { jComboBox2.addItem(rs.getString("KodeMenu")); } } catch (Exception e) { } } but when i build that was had warning like this … | |
can you resolve this warning? warning: [deprecation] getText() in JPasswordField has been deprecated | |
How to create a JDBC for Oracle and MySQL? | |
Dear All, Recently I have updated jre 1.7 with update 55 in client machine. When I open a applet application form loading time increased up to 1 min. The same application is working fine in java 1.6. As of my understanding this happens because of certificate revocation checks. When I … | |
First of all I apologize as my explainations is going to be lengthy I have a server that listens to incoming clients and they are connected to localhost. **Assuming that I only have 2 clients and assuming they only enter a text ONCE** so each time the client is connected, … | |
Hi all ive been thinking of a writing a compiler in java for my final year project. I have started to browse the net for help but to be honest its confused rather than helping me to get a clear image of what I would like to do. Ok.. let … | |
Hi all, for the below code: class A{ } class B extends A{ } why we extends 'A' class to inherit the properties in 'B'? Here we can use, class B{ A a = new A();//to get properties of 'A' class } why should we go for inheritance by using … |
The End.