Anonymous user
The Name Game: Difference between revisions
→{{header|Dyalect}}
m (Added Dyalect lang) |
|||
Line 746:
<lang dyalect>func printVerse(name) {
let y = "AEIOU".indexOf(x[0]) > -1 ? x.lower() : x[1..]
let b =
let f = x[0] is 'F' ? y
let m = x[0]
print("\(x), \(x), bo-\(b)")
print("Banana-fana fo-\(f)")
Line 769 ⟶ 758:
print()
}
let seq = yields { "Gary", "Earl", "Billy", "Felix", "Mary", "Steve" }
for x in seq {
printVerse(x)
|