I was able to submit a solution that was finally accepted. That said, my first attempt at a solution was getting the correct answer for every test suite scenario when it was run on the desktop version of the MATLAB, but the solution was nevertheless rejected. All I was doing was setting the end of a character vector to being empty (e.g. z(end) = [];), and I was being warned to use a logical or scalar value. This is a legitimate MATLAB command though.
Seleziona un sito web per visualizzare contenuto tradotto dove disponibile e vedere eventi e offerte locali. In base alla tua area geografica, ti consigliamo di selezionare: United States.
Puoi anche selezionare un sito web dal seguente elenco:
Come ottenere le migliori prestazioni del sito
Per ottenere le migliori prestazioni del sito, seleziona il sito cinese (in cinese o in inglese). I siti MathWorks per gli altri paesi non sono ottimizzati per essere visitati dalla tua area geografica.