Java, 5
These are very long... so I verified string equality using a Python script, and I generated this formatted post, so I wouldn't have to manually insert tabs on 400 lines.
class Main {
public static void main(String[] args) {
System.out.println("hello world");
}}
}
1
Main.java:5: error: class, interface, or enum expected
}
^
1 error
exit status 1
2
Main.java:1: error: class, interface, or enum expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:1: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:3: error: illegal start of type
^
^
Main.java:3: error: ';' expected
^
^
Main.java:6: error: ';' expected
exit status 1
^
Main.java:6: error: <identifier> expected
exit status 1
^
Main.java:6: error: reached end of file while parsing
exit status 1
^
10 errors
exit status 1
3
Main.java:1: error: class, interface, or enum expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:1: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: ';' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:2: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:2: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:3: error: illegal start of type
^
^
Main.java:4: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: <identifier> expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: ';' expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: illegal start of type
Main.java:1: error: <identifier> expected
^
Main.java:4: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:5: error: '(' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: ';' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:5: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:5: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:6: error: illegal start of type
^
^
Main.java:7: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: <identifier> expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: ';' expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: illegal start of type
Main.java:1: error: <identifier> expected
^
Main.java:7: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:8: error: '(' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: ';' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:8: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:8: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:9: error: illegal start of type
^
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: <identifier> expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: ';' expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: illegal start of type
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: illegal start of type
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: <identifier> expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: unclosed character literal
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: ';' expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: unclosed character literal
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:11: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: ';' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:11: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:11: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:12: error: illegal start of type
^
^
Main.java:12: error: <identifier> expected
^
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: ';' expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: <identifier> expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: ';' expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: unclosed character literal
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: unclosed character literal
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:14: error: <identifier> expected
Main.java:1: error: = expected
^
Main.java:14: error: ';' expected
Main.java:1: error: = expected
^
Main.java:14: error: illegal start of type
Main.java:1: error: = expected
^
Main.java:14: error: = expected
Main.java:1: error: = expected
^
Main.java:14: error: illegal start of type
Main.java:1: error: = expected
^
Main.java:15: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: illegal start of type
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: ';' expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:15: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:5: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:15: error: = expected
Main.java:5: error: class, interface, or enum expected
^
Main.java:16: error: illegal start of type
^
^
Main.java:17: error: = expected
Main.java:3: error: illegal start of type
^
Main.java:17: error: <identifier> expected
Main.java:3: error: illegal start of type
^
Main.java:17: error: ';' expected
Main.java:3: error: illegal start of type
^
Main.java:17: error: illegal start of type
Main.java:3: error: illegal start of type
^
Main.java:17: error: = expected
Main.java:3: error: illegal start of type
^
100 errors
exit status 1
4
Main.java:1: error: class, interface, or enum expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:1: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: ';' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:2: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:2: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:3: error: illegal start of type
^
^
Main.java:4: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: <identifier> expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: ';' expected
Main.java:1: error: <identifier> expected
^
Main.java:4: error: illegal start of type
Main.java:1: error: <identifier> expected
^
Main.java:4: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:5: error: '(' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: ';' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:5: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:5: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:6: error: illegal start of type
^
^
Main.java:7: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: <identifier> expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: ';' expected
Main.java:1: error: <identifier> expected
^
Main.java:7: error: illegal start of type
Main.java:1: error: <identifier> expected
^
Main.java:7: error: = expected
Main.java:1: error: <identifier> expected
^
Main.java:8: error: '(' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: ';' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:8: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:8: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:9: error: illegal start of type
^
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: <identifier> expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: ';' expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: illegal start of type
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: illegal start of type
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: <identifier> expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: unclosed character literal
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: ';' expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: unclosed character literal
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:10: error: = expected
Main.java:1: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
^
Main.java:11: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: ';' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:11: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:11: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:12: error: illegal start of type
^
^
Main.java:12: error: <identifier> expected
^
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: ';' expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: <identifier> expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: ';' expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: unclosed character literal
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: unclosed character literal
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:13: error: = expected
(use -source 1.4 or lower to use 'enum' as an identifier)
^
Main.java:14: error: <identifier> expected
Main.java:1: error: = expected
^
Main.java:14: error: ';' expected
Main.java:1: error: = expected
^
Main.java:14: error: illegal start of type
Main.java:1: error: = expected
^
Main.java:14: error: = expected
Main.java:1: error: = expected
^
Main.java:14: error: illegal start of type
Main.java:1: error: = expected
^
Main.java:15: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: illegal start of type
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: ';' expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: <identifier> expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:15: error: as of release 5, 'enum' is a keyword, and may not be used as an identifier
Main.java:1: error: class, interface, or enum expected
^
(use -source 1.4 or lower to use 'enum' as an identifier)
Main.java:15: error: = expected
Main.java:1: error: class, interface, or enum expected
^
Main.java:16: error: illegal start of type
^
^
Main.java:17: error: = expected
Main.java:2: error: <identifier> expected
^
Main.java:17: error: <identifier> expected
Main.java:2: error: <identifier> expected
^
Main.java:17: error: ';' expected
Main.java:2: error: <identifier> expected
^
Main.java:17: error: illegal start of type
Main.java:2: error: <identifier> expected
^
Main.java:17: error: = expected
Main.java:2: error: <identifier> expected
^
100 errors
exit status 1
5 (Quine) - Omitted because of post length.
11This procedure never produces an error quine in Pyth. It ends up in a repeating cycle, every third error output of which is
Segmentation fault (core dumped)
. – isaacg – 2015-05-30T04:49:27.0304@isaacg: That's actually pretty neat that it's cyclic. – Alex A. – 2015-05-30T04:51:16.613
5I believe this is the 3000th question, not counting closed or locked ones. Congrats! :) – Martin Ender – 2015-05-30T17:00:38.160
Too bad that C# can't do this, because the compiler generates an increasingly longer line of errors. – LegionMammal978 – 2015-05-30T18:40:39.833
Is it allowed to write a code that outputs another code with the errors included in it? – Ismael Miguel – 2015-05-31T03:23:18.930
@IsmaelMiguel: I'm not sure if I understood that correctly, but as long as it adheres to neither the original code or the code generated in any of the steps may produce non-error output, you should be fine. – Dennis – 2015-05-31T03:27:39.437
@Dennis What if it produces both, by outputting more code that generated more errors? In PHP, an example can be
<?=a.'<?="b<?=c";';
. – Ismael Miguel – 2015-05-31T03:29:20.717@Dennis I just did. But I will repeat:
<?=a.'<?="b<?=c";';
in PHP. – Ismael Miguel – 2015-05-31T03:32:40.953@IsmaelMiguel: That would be invalid because it prints
a<?="b<?=c";
to STDOUT, thus producing non-error output. – Dennis – 2015-05-31T03:34:00.990Alright, thanks. If you want, you can add that as an example of what not to do. – Ismael Miguel – 2015-05-31T03:34:38.190
1@IsmaelMiguel: I've added the last two iterations, to keep it short. – Dennis – 2015-05-31T04:13:53.983