/**
 * Given the name of an athlete, a start index, and an end index, this function returns the sliced portion of the athlete's name between the specified indices.
 *
 * @param athlete The name of the athlete.
 * @param startIndex The starting index of the slice.
 * @param endIndex The ending index of the slice.
 * @return The sliced portion of the athlete's name.
 *
 * Example:
 * athleteStats("Serena Williams", 3, 8) -> "ena W"
 * athleteStats("Roger Federer", 0, 5) -> "Roger"
 * athleteStats("Usain Bolt", 2, 9) -> "ain Bolt"
 */
fun athleteStats(athlete: String, startIndex: Int, endIndex: Int): String {

    var slicedName = ""

    for (i in startIndex until endIndex) {
        slicedName += athlete[i]
    }

    return slicedName
}
/**
 * Given the name of an athlete, a start index, and an end index, this function returns the sliced portion of the athlete's name between the specified indices.
 *
 * @param athlete The name of the athlete.
 * @param startIndex The starting index of the slice.
 * @param endIndex The ending index of the slice.
 * @return The sliced portion of the athlete's name.
 *
 * Example:
 * athleteStats("Serena Williams", 3, 8) -> "ena W"
 * athleteStats("Roger Federer", 0, 5) -> "Roger"
 * athleteStats("Usain Bolt", 2, 9) -> "ain Bolt"
 */
fun athleteStats(athlete: String, startIndex: Int, endIndex: Int): String {
/**
 * Given the name of an athlete, a start index, and an end index, this function returns the sliced portion of the athlete's name between the specified indices.
 *
 * @param athlete The name of the athlete.
 * @param startIndex The starting index of the slice.
 * @param endIndex The ending index of the slice.
 * @return The sliced portion of the athlete's name.
 *
 * Example:
 * athleteStats("Serena Williams", 3, 8) -> "ena W"
 * athleteStats("Roger Federer", 0, 5) -> "Roger"
 * athleteStats("Usain Bolt", 2, 9) -> "ain Bolt"
 */
fun athleteStats(athlete: String, startIndex: Int, endIndex: Int): String {

    var slicedName = ""

    for (i in startIndex until endIndex) {
        slicedName += athlete[i]
    }

    return slicedName
}