Skip to content

Latest commit

 

History

History
28 lines (20 loc) · 636 Bytes

File metadata and controls

28 lines (20 loc) · 636 Bytes

Sum (Java)

< Home

Print the sum of all the integers given as arguments to your Java program.

  • You cannot use the package java.util.

  • Your program can be a single file Sum.java or a zip file containing Sum.java.

  • Your program must use a method with the following signature:

    public static int sum(int[] nums)
  • You are allowed to also submit a readme.txt file.

Examples

java Sum 1 2 3 4 # 10
java Sum 15 99 134 # 248

Grade command

This is the command to set up the grader in RamDesk.

python {{grader.file_path}} {{submission.all_file_paths}}