Taiwo Sokunbi

Greenhorn
+ Follow
since Feb 01, 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
4
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Taiwo Sokunbi

Thanks a lot it worked
@Tony
10 years ago
Thanks for the suggestion will try to do that.

The GCompound is part of acm package that belongs to GObject .
10 years ago
Task : Write a GraphicsProgram subclass that draws a pyramid consisting of bricks arranged in horizontal rows, so that the number of bricks in each row decreases by one as you move up the pyramid.

But all I have been able to generate is right angled pyramid.
Below is the code I wrote.
Any help will be greatly appreciated.




10 years ago
Oops, that is typo error, it's suppose to be 2000th terms. And thanks for the constructive criticism, I will try to improve on those .
11 years ago
The program is to calculate the value of PI for the first 200th terms of the series : PI= 4 - 4/3 +4/5 - 4/7 + 4/9 - 4/11 + ...






public class FindingValueOfPie
{
public static void main(String []args)
{
double numerator = 4.0;

double pie = 0.0 , pie2=0.0;




for (int denominator=1; denominator<=2001; denominator+=4)
{


pie =pie + numerator/denominator;



}





for(int denominator2=3; denominator2<=2001 ; denominator2 +=4)

pie2 -= (numerator/denominator2);

pie= pie + pie2;





System.out.printf("final pie is : %.8f", pie);









}

}
11 years ago
@ Jesper de Jong. Thanks, i changed the directory and it worked!
12 years ago
Thanks everybody! I eventually got it through FAQ
12 years ago
sorry! i meant command prompt. i have tried to set the class path again but its bringing another error.

javac: file not found: myjavafilename
Usage:javac<Options><source files>
12 years ago
please i need help regard running java on DOS. Whenever i try to compile it say "javac is not recognized as an internal or external command, operable programor batch file". i have set my path variables.
12 years ago