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

 

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

Write a method that accepts an array of integers then returns that array with each pair of numbers swapped. Look at the test data for examples.


feb5_2016_APSLHL_swapPairs([]) → []
feb5_2016_APSLHL_swapPairs([7]) → [7]
feb5_2016_APSLHL_swapPairs([3, 9]) → [9, 3]

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

public int[] feb5_2016_APSLHL_swapPairs(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: 290

Copyright Nick Parlante 2017 - privacy