Created
November 3, 2017 21:35
-
-
Save madson/8d17cf3a776e65323357c82ffabcebea 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
import Foundation | |
var input = readLine()! | |
let upperCaseLetters = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" | |
var count = 1 | |
for letter in input.characters { | |
if upperCaseLetters.contains(String(letter)) { | |
count = count + 1 | |
} | |
} | |
print(count) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment