Posts
 
Reputation
Loading chart. Please wait.
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
~10.4K People Reached
Favorite Forums
Favorite Tags

13 Posted Topics

Member Avatar for student.09

What are you having trouble with exactly? I'm not going to spoonfeed you the entire Class but all you really need to get started is [code=java] public class MyPoint { private int x, y; } [/code]

Member Avatar for sahil_26
0
7K
Member Avatar for Traicey

Use something like [code="syntax"] if(exampeString.contains("-")) { // etc } [/code]

Member Avatar for stultuske
0
166
Member Avatar for kwins

[code] String fishX[] = {" Hakula"," Ngatala"," Atu"," Palukula"," Valu"," Takuo"," Mahimahi"};//fish menu double fishY[] = { 4.50, 6.75, 4.45, 4.80, 5.10, 4.20, 6.90,};//price of the fish int leng = fishY.length; double discount1 = 1.80; //discount 10% double discount2 = 7.20; // discount 20% double price = 0; double total …

Member Avatar for jon.kiparsky
0
238
Member Avatar for bulger2503

Is there a way to add data into a RandomAccessFile using seek(long) without writing over the data at that position and beyond? For example: [code] public static void main(String[] args) throws Exception { RandomAccessFile raf = new RandomAccessFile("test.txt", "rw"); raf.writeBytes("Hello, World!"); seek(2); raf.writeBytes("Goodbye, World!"); raf.close(); } [/code] Using that the …

Member Avatar for JamesCherrill
0
108
Member Avatar for WargRider

[code=java] public VarnaServer() throws Exception { System.out.println("Starting Server..."); System.out.println("Creating Server Socket"); server = new ServerSocket(3000, 50, InetAddress.getLocalHost()); System.out.println("Server Socket Created at: " + server.getInetAddress().getLocalHost()); this.start(); } [/code] I know it is marked as solved, however you can also use InetAddress.getLocalHost() to return the address.

Member Avatar for WargRider
0
2K
Member Avatar for SeanC

Following on from what jon.kiparsky said, protected also allows sub-classes direct access to the variable/method, whereas private does not and public would allow complete access to every class. Protected is in someways between public and private.

Member Avatar for bulger2503
0
127
Member Avatar for herrel17

[code=c] int main() { float principle, rate, n ,interest; int count = 0; while(++count <= 3) { printf("\nPlease enter the principle, rate and number: "); scanf("%f %f %f", &principle, &rate, &n); interest = (principle * rate * n) / 100; printf("%f", interest); } } [/code] Shouldn't all the variable except …

Member Avatar for bulger2503
0
155
Member Avatar for bulger2503

Hello, I just need some help in ByteBuffer's put(index, byte) method. Basically I have a byte array which stores data and is put into a ByteBuffer. The problem I'm facing is I want to put extra data in the ByteBuffer in index 2 (The positioning is very important) How would …

Member Avatar for ~s.o.s~
0
85
Member Avatar for bulger2503

Hello from Australia =] My question is rather simple but confusing. When i create abstract classes i alway create them so it can be extended at a later date by a normal class, The ByteBuffer in the nio package is unable to be extended due to its private constructor. In …

Member Avatar for ~s.o.s~
0
251
Member Avatar for prateeknigamk

[url]http://mindprod.com/jgloss/interfacevsabstract.html[/url] I think that is what you are after

Member Avatar for fireheart1024
0
95
Member Avatar for ymf

Instead of using finally, After the last out.print add out.close(); under it.

Member Avatar for ymf
0
123
Member Avatar for bulger2503

Hello. Currently i am creating a small application that works around packets. The packets are sent every 600ms. Now my quesition is this: Currently i have this (An example) [code="syntax"] public class Example { private int exampleInt = 0; public void setExample(int i) { exampleInt = i; } public void …

Member Avatar for bulger2503
0
144
Member Avatar for alpe gulay

Just an addition to mukulbhave's post Thread.sleep is in milliseconds to convert seconds to milliseconds seconds x 1000 (Just incase you didn't know)

Member Avatar for alpe gulay
0
137