A few training exercises with Swift