Not really a java question ... but anyway
Have you tried accessing the site which times out directly, rather than through an iframe?
What is serving the site - a web server, tomcat, j2ee server...
Err ... this is javascript not java !!!
Your code might work better if you do something along the lines of: check if input 1 is blank (null or zero length string). If it is, set its contents to id,...
You do not need to pass in the argument (double numberOfCups) to getCups. You should declare numberOfCups as a double within the method.
You could make the method more resilient. What would happen...
You are synchronizing to two separate objects - the "this" in each case is the anonymous inner class.
If you add another object to synchronize to and change both synchronized(this) to...
OK - if you want to do it without using "built in" functions, then you could create a character array from the original string, another character array to hold the revered string, populate it and...
First problem is in the sqArea function. You pass it a SquareObject argument, but it looks as if the argument should be a Square ... and not the Square class itself but an instance of the Square...
1. That should meet the requirement. You need to be sure that you don't define a buffer or some other temporary storage outside the while loop and write to it inside the loop, otherwise you risk...
You could make isPalindrome() take a String argument, and make it static. That way you don't need to create an instance of the Palindrome class in main.
http://stackoverflow.com/questions/525212/how-to-run-unix-shell-script-from-java-code
But not generally a good idea because it ties your (portable) java application to unix/linux systems....
Outside main, you define static Console c ... inside main you create a new Console(), then call methods like readString() on c which has not been initialized.
Better to define console c = new...
First thing I'd do is get rid of the big switch statement - firstly, switch(String) only works in Java 1.7 and secondly, it's only providing a map of grade (A, B+ etc) to a score (4, 3.67 etc). You...
You have some code which more or less works, but is not pretty in its function or its presentation.
Indentation is seemingly random with a mixture of tabs and spaces - try to stick to one or the...
OK ... you need a "buffer" to hold the input and loop which repeatedly asks for input and either (1) adds this to the buffer or (2) exits when the input is "done". Something like ...
What you need is an array of integers to hold the user input once it has been validated (i.e. converted to integers as you are doing with Integer.parseInt), a for loop to populate the array, and...
You should use "code tags" when posting code on the forum ... it maintains the formatting!
I assume TPar is the running total for par, TPlayer1 the running total for player 1 etc.
You are almost...
Your "user name generator" post from 20th January contains an example of the code you need to do this ... i.e. String.split(), this time using the colon as the delimiter.
I'm guessing your input is a number of seconds .... so calculating hours is easy:
int hours = Total / 3600;
Minutes is where you need the modulus operator ... and divide the result by 60:
int mins...