Last active
September 30, 2020 09:58
-
-
Save tkgshn/09ab9afe2409e47cf7c5799d75e8c827 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// MARK: - やりたいこと | |
//japanese(日本語)を3つほどランダムで表示する | |
// MARK: - Code | |
////フレーズという辞書を定義する | |
let phrases = [ | |
["japanese": "私", "english": "I", "phraseAudioName" : "人称"], | |
["japanese": "私とあなた", "english": "I and You", "phraseAudioName" : "国と言語"], | |
["japanese": "私たち", "english": "both of us", "phraseAudioName" : "人称"], | |
["japanese": "彼", "english": "he", "phraseAudioName" : "国と言語"], | |
["japanese": "彼と彼女", "english": "he and she", "phraseAudioName" : "人称"], | |
["japanese": "彼ら", "english": "they both", "phraseAudioName" : "国と言語"], | |
] | |
// まずは全ての数字を出す | |
let phrases_count = phrases.count | |
// 最初から最後までループさせる | |
for n in 0..<phrases_count { | |
print(phrases[n]["japanese"]!) | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
とりあえず公開