There was an error while loading. Please reload this page.
Write a function that given a list of non negative integers, arranges them such that they form the largest possible number.
For example, given [50, 2, 1, 9] the largest formed number is 95021.
//src/AppBundle/Controller/Test5Controller public function test5Action(Request $request) { $list = $request->request->get('list'); $result = null; return new JsonResponse($result, JsonResponse::HTTP_OK); }
$ curl -H "Content-Type: application/json" -X POST -d '{'list':[50, 2, 1, 9]}' test.local/test5 95021