id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

jebbert@volusia.k12.fl.us > test2021_06_03_APP1SL_reverseArray
prev  |  next  |  chance

Write a method that returns a copy of the 'nums' array, but in reverse order. Note that 'nums' can be any length. NOTE: You are NOT allowed to use maps, functional programming, strings, or array lists. You are NOT allowed to have any nested loops or nested recursion. You are NOT allowed to make a giant array that is way longer than the input parameter arrays. Kyle, you must resist your natural impulses!


test2021_06_03_APP1SL_reverseArray([152, 44, 75, 856]) → [856, 75, 44, 152]
test2021_06_03_APP1SL_reverseArray([3, 2, 1]) → [1, 2, 3]
test2021_06_03_APP1SL_reverseArray([-423]) → [-423]

...Save, Compile, Run (ctrl-enter)

public int[] test2021_06_03_APP1SL_reverseArray(int[] nums) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 220

Copyright Nick Parlante 2017 - privacy