32,204 Topics
| |
Let's say that i have an array of objects. So, I need to delete the count objects starting at the given index. Make sure to compress myObjects and update currentObject. You must also verify that the given index exists in myObjects and that there are count entries starting from there. … | |
Hi, i have some RMS data in my memory, i want to store it and draw it into the scrollable UI canvas? How do i do it? | |
Is it possible to create an application that prevent users from running certain applications for a certain period of time using java? Like when a user logs in the pc, only applications that was allowed in his access level would run. Thanks in advance :) | |
Let's say that i have an array of objects. So, I need to delete the object at the given index and make sure to compress myObjects and update currentObject. Also, I have to verify that the given index exists in myObjects. This is what I got: NOTE: I will just … | |
Hi, I have a quick question. I am making a hang man game for project (I am at university as a computer science major), I have completed most of the game but have run into one small issue which has been given me a big problem. Right now I am … | |
**I have a half complete coding which basically comes down to a gui interface. The problem is that I don't know how to get it working as ticket vending machine with fixed rates and fixed amount of cash being able to put in. So, far, I've done up to calculating … | |
I am working on this editDistance program in Java, but I cant figure out how to return the new strings..... The program is returning the editDistance, but everytime a char doesnt match I want to delete it out of the string, in the end when I call printDistance(), I want … | |
In this main class I used a **ListIterator** variable, **hasnext()** and **next()** method to print LIST memebers. I created litr variable of ListIterator, I performed some functions on the list i.e, sorting(ascending and descending) etc. I used the same litr variable and a while loop for outputing the list again … | |
`Inline Code Example Here` import java.io.*; import java.util.regex.*; String []str = {"123","0959","75443","19908","1","11879","1119","276","566777","7","675","4435","54","6588","99","124","78"}; String filename = "temp.text"; try{ File file = new File(filename); FileWriter fw = new FileWriter(file); for(int i=1;i<=str.lenght;i++){ // Start for BufferedWriter bw = new BufferedWriter(fw); bw.write(str); bw.newLine(); } // End for bw.close(); }catch(IOException ex){ System.out.println("Error.."+filename+" "); } public … | |
Hi Dw I've been so interested in to java because so far it makes almost my dreams come true with it flexibility of fitting almost every where or anywhere, so I'm having a thought here for mobile phones, I want to create a certain program or my sim card I … | |
Here is sample Requirement! I need Java Web Services Sample Project implemented in both RPC & RMI. Functional Requirements: Login Add Student Update Student Search Student Delete Student Database: MySQL Can I get it now???? Thanks for your time and consideration! | |
hi all ! does anyone know how to open up the window of a normal program from a graphics window in Blue J | |
| Write a new method named count(E o) that returns the number of elements in the list that are equivalent to the specified object. Write a new method named reverse() that reverses the order of the nodes in the list. Can you figure out a way of doing this non-recursively in … |
| |
I have this method I'm trying to the return is the student that will be removed and then remove student at pos I tried almost everything I put the return outside the if statment , but I still get error I also tried to substract 1 from the size but … | |
I am trying to add actions and paint on the image in JPanel. Till now I could only succeed to add image into the JPanel. But I could not add mouse actions on the image and paint it. Can anyone please go through my code and give suggestions!! public class … | |
You will use the P10Class here: public class P10Class public class P10Class { public static int SEQ_NUM; public static int BIN_NUM; public static int seq_search(int[] data, int key) { boolean found = false; int i = 0; SEQ_NUM = 0; while ( !found && (i < data.length) ) { if … | |
Honestly am writing an application and am stuck at this point. problem is am writing an asset derpreciation application and i am calculating for Monthly Depreciation,End-of-year value ,Accumulated depreciatio.I want get the results of the values in this form in my jTable when the calculation is done. for example when … | |
Hey guys trying to make this OO but no luck..can anyone help? import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.io.*; import java.util.*; public class Main implements ActionListener { public static void main(String[] args) { new Main();// Calling the class construtor. }//end main //Setting up ALL the variables JFrame window = … | |
Hey guys, so I'm making a board game in java similar to X's and O's on a 4x4 grid but there's different types of pieces etc., but what must be done is you must pick a piece to give to your opponant for them to place on the board and … | |
hello everyone, am here to solve a problem and i need advice from u ppl. i have my database consist of 7 tables which generates a java web application. (Spring,Jsf,primefaces,java) when the user login, only the data for that particular user from the tables should be displayed. I was thinking … | |
Good morning! I have these VideoChatRTP class I got [here](Good morning! I have these VideoChatRTP class I got here (I just added the main) and an EncodingUtilClass class from here.) (I just added the main) and an EncodingUtilClass class from [here](http://www.java2s.com/Open-Source/Java/6.0-JDK-Modules/java-3d/com/db/media/rtp/EncodingUtil.java.htm). VideoChatRTP.java import javax.media.rtp.*; import javax.media.*; import javax.media.protocol.*; import java.awt.Image; … | |
Good morning! I have these VideoChatRTP class I got [here](http://www.java2s.com/Open-Source/Java/6.0-JDK-Modules/java-3d/com/db/media/rtp/VideoChatRTP.java.htm) (I just added the main and made player static) and an EncodingUtilClass class from [here](http://www.java2s.com/Open-Source/Java/6.0-JDK-Modules/java-3d/com/db/media/rtp/EncodingUtil.java.htm). VideoChatRTP.java import javax.media.rtp.*; import javax.media.*; import javax.media.protocol.*; import java.awt.Image; import java.io.*; import java.net.*; import com.sun.media.ui.*; /** * A RTP over UDP player which will receive … | |
import java.util.Scanner; import java.util.Arrays; public class project { private static Scanner keyboard = new Scanner(System.in); public static void main() { double row [][]; int positionInRow, numberInRow, rowSize, index, numberOfRows,weight; int maxWeight = 100; System.out.println("Welcome to the Band of the Hour"); System.out.println("-------------------------------"); System.out.print("Please enter number of rows : "); numberOfRows = … | |
Hi all, Wondering if anyone could help - I have a project I'm working on - part of it involves loading a list of resource files at runtime. I can hardcode each file and use the ClassLoader.getResource("....") to get each file, but I was wondering is there a way to … | |
I try read values from CSV file using commonCSV parser. The file has values like this. Name,Phone,Country,languageknown gary,423432,USA,[English,spanish,German] After parsing I iterate, I get value like this, gary 423432 USA [English spanish German]. But i want like this, gary 423432 USA [English,spanish,German] the braces contain one full string but it … | |
Hello, I'm trying to write a program that takes an input file name and lists the folders in a heirarchy ex.Folder subfolder etc I have most of my code, but I'm getting 2 errors that are connected and I have no idea how to fix it. Here is my code: … | |
I'm practcing for my test and I couldn't solve these questions I spent hours trying to solve it but every time I get error ArrayList<objClass> li = new ArrayList<>(); public objClass RemoveAtPos(int pos){ // I'm trying to remove the object at the given pos , but first I want to … | |
Hey guys, I have a program similar to X's and O's. But I need to put the "CheckWin" method in another class and call it from there. Im having no luck, can anyone help? (CHECKWIN PART AT VERY BOTTOM) import javax.swing.*; import java.awt.*; import java.awt.event.*; import java.io.*; import java.util.*; public … | |
The End.