I have a line description that contains my sentence. I only want to make amends for the first letter. I tried different things, but most of them give me exceptions and errors. Im using Xcode 6.
Here is what I have tried so far
let cap = [description.substringToIndex(advance(0,1))] as String description = cap.uppercaseString + description.substringFromIndex(1)
This gives me: Type 'String.Index' does not comply with IntegerLiteralConvertible protocol
I tried
func capitalizedStringWithLocale(locale:0) -> String
But I just can't figure out how to make it work. Any ideas?
source share