fork download
  1. #define cardinal 5
  2. substitute=1
  3. initially=0
  4. initially2=cardinal/2
  5. loop:
  6. initially_intermediate=initially
  7. initially2_intermediate=initially2
  8. arr[initially][initially2]=substitute;
  9. initially=initially-1
  10. initially2=initially2+1
  11. arr[initially][initially2]=substitute;
  12. initially=initially-1;
  13. initially2=initially2+1;
  14. initiallyf(initially<0)
  15. initially=n-1
  16. initiallyf(initially2>cardinal-1)
  17. initially2=0;
  18. Condition: arr[initially][initially2]!=0
  19. initially=initially_intermediate+1
  20. initially2=initially2_intermediate
  21. end Condition
  22. substitute++
  23. end loop condition substitute < = square(cardinal)
  24. flag=arr[3][2]+arr[2][3]*arr[4][3]-arr[1][0]/arr[0][4]
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
Main.scala:1: error: expected class or object definition
#define cardinal 5
^
Main.scala:2: error: expected class or object definition
substitute=1
^
Main.scala:3: error: expected class or object definition
initially=0
^
Main.scala:4: error: expected class or object definition
initially2=cardinal/2
^
Main.scala:5: error: expected class or object definition
loop:
^
Main.scala:7: error: expected class or object definition
initially2_intermediate=initially2
^
Main.scala:8: error: expected class or object definition
arr[initially][initially2]=substitute;
^
Main.scala:9: error: expected class or object definition
initially=initially-1
^
Main.scala:10: error: expected class or object definition
initially2=initially2+1
^
Main.scala:11: error: expected class or object definition
arr[initially][initially2]=substitute;
^
Main.scala:12: error: expected class or object definition
initially=initially-1;
^
Main.scala:13: error: expected class or object definition
initially2=initially2+1;
^
Main.scala:14: error: expected class or object definition
initiallyf(initially<0)
^
Main.scala:15: error: expected class or object definition
initially=n-1
^
Main.scala:16: error: expected class or object definition
initiallyf(initially2>cardinal-1)
^
Main.scala:17: error: expected class or object definition
initially2=0;
^
Main.scala:18: error: expected class or object definition
Condition: arr[initially][initially2]!=0
^
Main.scala:19: error: expected class or object definition
initially=initially_intermediate+1
^
Main.scala:20: error: expected class or object definition
initially2=initially2_intermediate
^
Main.scala:21: error: expected class or object definition
end Condition
^
Main.scala:22: error: expected class or object definition
substitute++
^
Main.scala:23: error: expected class or object definition
end loop condition substitute < = square(cardinal)
^
Main.scala:24: error: expected class or object definition
flag=arr[3][2]+arr[2][3]*arr[4][3]-arr[1][0]/arr[0][4]
^
23 errors found
Usage: scalac <options> <source files>
where possible standard options include:
  -Dproperty=value                Pass -Dproperty=value directly to the runtime system.
  -J<flag>                        Pass <flag> directly to the runtime system.
  -P:<plugin>:<opt>               Pass an option to a plugin
  -X                              Print a synopsis of advanced options.
  -bootclasspath <path>           Override location of bootstrap class files.
  -classpath <path>               Specify where to find user class files.
  -d <directory|jar>              destination for generated classfiles.
  -dependencyfile <file>          Set dependency tracking file.
  -deprecation                    Emit warning and location for usages of deprecated APIs.
  -encoding <encoding>            Specify character encoding used by source files.
  -explaintypes                   Explain type errors in more detail.
  -extdirs <path>                 Override location of installed extensions.
  -feature                        Emit warning and location for usages of features that should be imported explicitly.
  -g:<level>                      Set level of generated debugging info. (none,source,line,vars,notailcalls) default:vars
  -help                           Print a synopsis of standard options
  -javabootclasspath <path>       Override java boot classpath.
  -javaextdirs <path>             Override java extdirs classpath.
  -language:<_,feature,-feature>  Enable or disable language features: `_' for all, `-language:help' to list
  -no-specialization              Ignore @specialize annotations.
  -nobootcp                       Do not use the boot classpath for the scala jars.
  -nowarn                         Generate no warnings.
  -optimise                       Generates faster bytecode by applying optimisations to the program
  -print                          Print program with Scala-specific features removed.
  -sourcepath <path>              Specify location(s) of source files.
  -target:<target>                Target platform for object files. All JVM 1.5 targets are deprecated. (jvm-1.5,jvm-1.6,jvm-1.7,jvm-1.8) default:jvm-1.6
  -toolcp <path>                  Add to the runner classpath.
  -unchecked                      Enable additional warnings where generated code depends on assumptions.
  -uniqid                         Uniquely tag all identifiers in debugging output.
  -usejavacp                      Utilize the java.class.path in classpath resolution.
  -usemanifestcp                  Utilize the manifest in classpath resolution.
  -verbose                        Output messages about what the compiler is doing.
  -version                        Print product version and exit.
  @<file>                         A text file containing compiler arguments (options and source files)

spoj: The program compiled successfully, but Main.class was not found.
      Class Main should contain method: def main(args: Array[String]).
stdout
Standard output is empty