forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice lasa_drills_01 > LASA_startWorking
prev  |  next  |  chance


Given an integer h, an integer m, and an array of integers, of length n. n is the number of tasks someone has to get done, and h:m is the time it has to be done by (24 hour format. h=13 is 1:00, h=14 is 2:00, so on). The array of integers is how long it takes (in minutes) to get each task done. Find the latest time (in hours and minutes) someone has to start working in order to get their tasks done before the deadline. The start time may need to be on the previous day. (return in this form, 24hr format: HH:MM)

LASA_startWorking(12, 0, [10, 20, 5, 15, 30]) → "10:40"
LASA_startWorking(20, 30, [15, 16]) → "19:59"
LASA_startWorking(10, 0, [1, 2, 3, 4]) → "9:50"

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

String LASA_startWorking(int h, int m, int[] arr){ }

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

Copyright Nick Parlante 2017 - privacy