[−][src]Function voca_rs::index::last_index_of
pub fn last_index_of(subject: &str, search: &str, from_index: usize) -> i8
Returns the last occurrence index of search
in subject
or -1 if not found. Case sensitive.
Arguments
subject
- The string where to search.search
- The string to search.from_index
- The index to start searching
Example
use voca_rs::*; index::last_index_of("morning", "n", 0); // => 5 index::last_index_of("evening", "o", 0); // => -1