So for this question, your goal is to define a procedure, named "find_last," that takes as input 2 strings.
The first string is a search string; the second string is the target string.
And it outputs the last position in the search string where the target string appears, as long as it appears at least once.
If it doesn't appear at all, then the output should be -1.
Así que para esta pregunta, su objetivo es definir un procedimiento, llamado "find_last", que toma como entrada 2 cuerdas.
La primera cadena es una cadena de búsqueda; la segunda cadena es la cadena de destino.
Y da salida a la última posición en la cadena de búsqueda en el que aparece la cadena de destino, siempre que aparece al menos una vez.
If it doesn't appear at all, then the output should be
Per questa domanda, il vostro scopo è definire una procedura, chiamata "find_last", che riceva due stringhe come parametri
La prima è la stringa su cui cercare; la seconda è quella da trovare
e stampi l'ultima posizione nella stringa da cercare laddove la stringa da trovare appare, sempre che appaia almeno una volta.
Se non appare per nulla, allora si dovrebbe stampare -1
この問題では 次のような処理を行う
find_last関数を定義してください
find_lastは入力として2つの文字列を受け取ります
1つ目は検索対象となる文字列で
2つ目は見つける文字列です
少なくとも1回出現する場合は
検索対象の文字列において
見つける文字列が出現する最後の位置を出力します
見つける文字列がまったく出現しない場合は
-1を出力します
Para esta questão, sua tarefa ;e definir um procedimento, chamada find_last, que recebe como entrada 2 strings --
a primeira string é a string de pesquisa; a segunda string é a string alvo.
E a saída é a última posição no string de pesquisa, na qual a string alvo ocorre, desde que ela ocorra pelo menos uma vez.
Se ela não ocorrer nenhuma vez, a saída deve ser -1.
對於這個問題,你的目標是定義程序 find-last,
需要輸入 2 個字串
第一個字串是搜尋字串 (search string),
第二個字串是標靶字串 (target string)
它要輸出:搜尋字串中,只要標靶字串至少出現一次,
傳回標靶字串最後出現的位置
如果它完全沒出現,那麼輸出應該是 -1