Skip to content

Instantly share code, notes, and snippets.

@hirokazumiyaji
Created June 4, 2014 14:18
Show Gist options
  • Save hirokazumiyaji/0389cb3c4fb70293ecdf to your computer and use it in GitHub Desktop.
Save hirokazumiyaji/0389cb3c4fb70293ecdf to your computer and use it in GitHub Desktop.
swift sample
var count = 0
for scene in scenes {
if scene.hasPrefix("Act 1") {
count += 1
}
}
count = scenes.filter({$0.hasPrefix("Act 1")}).count
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment