fork download
  1. /* package whatever; // don't place package name! */
  2.  
  3. import java.net.HttpURLConnection;
  4. import java.net.URL;
  5.  
  6. /**
  7.  * Created by tobidae on 2/21/17.
  8.  */
  9. public class Ideone {
  10. public static void main (String[] args){
  11. String[] chars = {
  12. "a", "b", "c", "d", "e",
  13. "f", "g", "h", "i", "j",
  14. "k", "l", "m", "n", "o",
  15. "p", "q", "r", "s", "t",
  16. "u", "v", "w", "x", "y",
  17. "z"};
  18. String word;
  19. for (String a: chars){
  20. for (String b: chars){
  21. for (String c: chars){
  22. for (String d: chars){
  23. word = a + b + c + d;
  24. try {
  25. URL url = new URL("https://w...content-available-to-author-only...e.edu/homes/bxd/" + word + ".html");
  26. HttpURLConnection http = (HttpURLConnection)url.openConnection();
  27. int statusCode = http.getResponseCode();
  28. if (statusCode == 304){
  29. System.out.println("Quiz Links: https://w...content-available-to-author-only...e.edu/homes/bxd/" + word + ".html");
  30. }
  31. } catch (Exception e){
  32.  
  33. }
  34. }
  35. }
  36. }
  37. }
  38. }
  39. }
  40.  
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Main.java:9: error: class Ideone is public, should be declared in a file named Ideone.java
public class Ideone {
       ^
1 error
stdout
Standard output is empty