Results 21 to 28 of 28
Thread: Help need on math java program
- 06-30-2010, 04:08 PM #21
Member
- Join Date
- Jun 2010
- Posts
- 8
- Rep Power
- 0
- 06-30-2010, 04:13 PM #22
- Join Date
- Sep 2008
- Location
- Voorschoten, the Netherlands
- Posts
- 11,399
- Blog Entries
- 7
- Rep Power
- 17
-
It has nothing to do with your being a good or bad programmer and all to do with being inconsiderate. At least read and answer the responses in your cross-post. Else, why should people take time out to help you if you don't at least let them know that you are taking the time to read what they post?
- 06-30-2010, 05:25 PM #24
Member
- Join Date
- Jun 2010
- Posts
- 8
- Rep Power
- 0
I am thankful for any help that is given to me. It is appreciated. And I am sorry for cross posting as I was unaware it was so irritating to people and I do read all the replies to the posts I have. I may not understand them all but I do read them. I am just trying to ask people who are more experienced than me in java for help. So please show a little patience and tolerance, and please dont be offensive by saying you hate me Fubarable, JosAh is right you don't even know me. If you did you would know that I am not trying to irritate anybody I genuinely asking for some help.
By the way thank you JosAh for the code you wrote it works and prints out the values in the terminal (linux), however I wish for the values to be printed in the text file "value-of-y.txt"
Again thanks.
- 06-30-2010, 05:29 PM #25
Senior Member
- Join Date
- Feb 2010
- Location
- Ljubljana, Slovenia
- Posts
- 470
- Rep Power
- 4
Reading from and writing to files must be one of the most asked questions for pretty much any programming language. Has it ever occured to you to go to a nifty little page called Google and typing in "java writing to file"? Or better yet, have you heard of a company called Sun? I hope so since they made Java, and I have a hunch that their website contains many guides, tutorials and examples on any questions and themes you might have.
EDIT: Ok, I reread my reply and I came of as kind of a condescending prick. That was not my intention, was just trying to be sarcastic.Ever seen a dog chase its tail? Now that's an infinite loop.
-
- 06-30-2010, 06:00 PM #27
- Join Date
- Sep 2008
- Location
- Voorschoten, the Netherlands
- Posts
- 11,399
- Blog Entries
- 7
- Rep Power
- 17
Do this before my code runs:
and do this after my code has run:Java Code:PrintStream oldOut= System.out; System.setOut(new PrintStream(new FileOutputStream("yourfile.txt")));
... and leave my code unchanged ...Java Code:System.out.close(); System.setOut(oldOut);
kind regards,
Jos
- 07-07-2010, 02:48 AM #28
Senior Member
- Join Date
- Feb 2010
- Location
- Waterford, Ireland
- Posts
- 748
- Rep Power
- 4
Similar Threads
-
Math Program
By stlboi in forum New To JavaReplies: 8Last Post: 04-02-2009, 09:34 PM -
need help with math for a new program
By gotenks05 in forum New To JavaReplies: 13Last Post: 09-26-2008, 07:32 AM -
Java Math
By levent in forum Java TutorialReplies: 1Last Post: 05-12-2008, 09:03 AM -
java.lang.Math
By eva in forum New To JavaReplies: 2Last Post: 01-31-2008, 04:17 PM -
Help with math in java
By fernando in forum New To JavaReplies: 1Last Post: 08-06-2007, 06:05 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks