Created
February 6, 2015 14:15
-
-
Save matsuyoro/f8f4db7fd77bbc096608 to your computer and use it in GitHub Desktop.
Swift 指定位置の文字列を置換する ref: http://qiita.com/matsuyoro/items/b0e119256d498a03a60d
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
var str:NSString = "ABCDEFGHIJKLMNOP" | |
var pos = NSMakeRange(4,4) // 位置 | |
println(str.stringByReplacingCharactersInRange(pos, withString: "hoge")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment