You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
640 B
35 lines
640 B
//
|
|
// File.swift
|
|
//
|
|
//
|
|
// Created by Louis DUFOUR on 15/01/2024.
|
|
//
|
|
|
|
import Foundation
|
|
|
|
public enum Animal: String { case rat, cat, dog, wolf, leopard, tiger, lion, elephant
|
|
|
|
public var description: String {
|
|
switch self {
|
|
case .rat:
|
|
return "Rat"
|
|
case .cat:
|
|
return "Cat"
|
|
case .dog:
|
|
return "Dog"
|
|
case .wolf:
|
|
return "Wolf"
|
|
case .leopard:
|
|
return "Leopard"
|
|
case .tiger:
|
|
return "Tiger"
|
|
case .lion:
|
|
return "Lion"
|
|
case .elephant:
|
|
return "Elephant"
|
|
}
|
|
}
|
|
}
|
|
|
|
|