Akira Reddy

Greenhorn
+ Follow
since Dec 14, 2012
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Akira Reddy

i could finally resolve the issue. I have followed the procedure of writing contents to another file and inserting the text wherever i need. Thank you all for your help.
7 years ago
Hi,
   I would like to write to a file after a set of characters. For example, if I want to write "xyz" into a File "test.txt" which contains string "hello world". I want write after the letter w. The output should be "hello wxyzorld" in the file. How do it do it? Using a FileWriter and BufferedWriter I can write to a file but not at a certain position. Could you help me if there is anyway i can do it?

Thanks,
Aravind
7 years ago
Hi, I am trying to sum two numbers using java.

below is the code that i have written

is this correct?

7 years ago
Thank you for clarifying. I really appreciate your help.
10 years ago
Hi Joe,
Thank you for replying. I have used the gettimeinmillis from calendar and have implemented it. I got the result. Thanks.

Hi Winston,
I looked at joda time class. And have used daysimplemented method. but why is it that i m getting 4827 instead of 4826. Could you please explain? below is my code


10 years ago
Hi,
I am trying to solve this below question.I have looked at the JDate and GDate code.
java DaysOld 2000-2-2
You were born on February 2, 2000
Today is April 19, 2013
You are now 4825 days old.

And below is the algorithm that I came up.

so from 2000 to 2013 i find the leap years
2004, 2008, 2012
see if it is leap year or not

for leap years count sum=sum+366 days
else sum=sum+ 365 days

finding days in month from feb 2nd 26+31 feb+mar

and in 4th month i have to add +19 and that gives me 4825.

Is this how I should approach the problem?

Initially I have copied the String argument into .

After this do I have any function which can directly find the difference between dates or
do I have to implement the above algorithm that I have written?

Could you suggest which direction I should be going?
10 years ago
Thank you posting the replies. Next time I will frame my question more accurately :-). But I really appreciate you all for replying very quickly. Thank you so much.
11 years ago
Thank you Fred and Stevens for responding. I liked both your approaches. My next question would have been what Stevens asked me. To print the letters right next to each other. Taking the Fred's approach, I would write the print statements such that it prints ABC. I think I would write my code in below style. But I do not know any other way of doing it.

11 years ago
Hi,
I am trying to print letters in asterik format. Below is my code for printing letter 'A'. Is there any better of way of doing it? Suggest me if there is any alternative way of doing. Because I would like to do it for all the letters. Thanks in advance for any replies.

11 years ago