Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
Ranked #2K
~3K People Reached
Interests
Programming, OS Development
PC Specs
Linux
Favorite Forums
Favorite Tags
java x 23
Member Avatar for NewOrder

i have a bit a weak understanding of those 2 concepts. could you explain to me what is happening in that part of the code? [CODE] public class Part5{ public static void main(String[] args) { // Object[] zoo=new Object[4]; // zoo[0]=new Cat(); Object[] animals=new Object[4]; animals[0]=new Cat(); animals[1]=new Dog(); animals[2]=new …

Member Avatar for NewOrder
0
112
Member Avatar for glenak

Hi, I want to code a client/server app such that there will be one server and multiple clients interacting with the server. The clients will send messages, like "Hello, server," and the server will send messages back. I know how to write a simple client/server app, however im confused as …

Member Avatar for glenak
0
219
Member Avatar for developer@india
Member Avatar for hmarie88

I keep getting these errors when I try to run the program Exception in thread "main" java.lang.NumberFormatException: For input string: "GTR" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:48) at java.lang.Integer.parseInt(Integer.java:449) at java.lang.Integer.parseInt(Integer.java:499) at Inventory6.addProductToInventory2(Inventory6.java:549) at Inventory6.main(Inventory6.java:734) I've spent hours trying to figure out what I'm doing wrong and it's due in a few hours. I …

Member Avatar for hmarie88
0
98
Member Avatar for JamesCherrill

I have a problem involving Generics. Here's a simplified version: Suppose I have a generic method to add a new element to a (possibly empty) ArrayList, like this: [CODE]<T> void addNewTo(ArrayList<T> list)[/CODE] What I need to do is to determine the correct class for the ArrayList elements so as to …

Member Avatar for JamesCherrill
0
186
Member Avatar for chaos123456

Hi all [CODE]import java.io.*; public class POManager { private static String posFname = "C:/ITM200/OOP-Advanced-Topics/src/po.txt"; private static String taxposFname = "C:/ITM200/OOP-Advanced-Topics/src/tax.txt"; public static void main(String [] args) throws IOException { PO[] pos = readPOFile(); writePOTaxFile(pos); } public static PO[] readPOFile() throws IOException { BufferedReader in = new BufferedReader(new FileReader(posFname)); in.readLine(); String …

Member Avatar for chaos123456
0
629
Member Avatar for pateldeep454

My code: [CODE] package big; import java.math.BigInteger; public class Main { public static void main(String[] args) { System.out.println (factorial (5)); } public static int factorial (int n) { int f = 1; for (int i = 1; i <= n; i++) { f = f * i; } return f; …

Member Avatar for pateldeep454
0
141
Member Avatar for jiraiya

Hi all, Does anyone know of a way to scan a character from the command line without the enter key having to be pressed? For example, the user would type 'a', which is then picked up and scanned by the program and stored, etc. The only way of scanning input …

Member Avatar for jiraiya
0
139
Member Avatar for BuhRock

Can someone help me with error trapping. For instance, if I asked the user to input only a numeric type, 0-9. Then how would I go about creating an error message if the user inputs "hey." I know that I could easily use the Try, Catch statements but I want …

Member Avatar for chaospie
0
131
Member Avatar for mahdi68

Hi how can i get linux distributions name in java ??? i try it by Syatem.getProperty("os.name") but this return only "Linux" !!! is any way to return like fedora , suse , ... ??? thanks

Member Avatar for chaospie
0
92
Member Avatar for pateldeep454

My task is: The Captain Crunch decoder ring works by taking each letter in a string and adding 13 to it. For example, ’a’ becomes ’n’ and ’b’ becomes ’o’. The letters “wrap around” at the end, so ’z’ becomes ’m’. Write a method that takes a String and that …

Member Avatar for pateldeep454
0
898
Member Avatar for kesh1000

hi all i need a bubble sort algorithm in Java and make a class bubble_sort to sort any given array of any user defined type. can any of u give me a basic algoruthm i need to work with????

Member Avatar for chaospie
0
233
Member Avatar for bufospro

Hi, I am trying to write to a .txt file an integer but the characters I see when I open the file are strange. Could you tell me what happens ?? [CODE] import java.io.*; public class A { public static int readInt() { byte b[] = new byte[16]; String str; …

Member Avatar for bufospro
1
121