3. how can reverse numbers in a string when they are split with "-"? It has to be in java, manually, no imports allowed, although we are allowed to use only methods/functions from the String class....


3.


how can reverse numbers in a string when they are split with "-"? It has to be in java, manually, no imports allowed, although we are allowed to use only methods/functions from the String class. please explain too so I can study!<>


example:
input: 3-1, 4, 5, 6-9
output: 1-3, 4, 5, 6-9
another example:


input: 1-6, 8, 9-12, 16-13, 17
output expected: 1-6, 8, 9-12, 13-16, 17



Jun 07, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here