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

 

andersoniii.edwin@cusd80.com > smallAndBig
prev  |  next  |  chance

SmallandBig - Write the method that receives an array of integers and returns an array of integers just containing the smallest and biggest number of the given array. If the array is empty return the [0,0]. Example [2,4,6,8,0] [0,8]


smallAndBig([1, 2, 3, 4, 5, 6, 7, 8]) → [1, 8]
smallAndBig([4, 1, 4, 2, 4, 3, 4, 5]) → [1, 5]
smallAndBig([3, 4, 3]) → [3, 4]

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

public int[] smallAndBig(int[] list ){ }

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: 110

Copyright Nick Parlante 2017 - privacy