I have a string of test@me
now I want to create a code that let me cut where the @ is and save it as a variable, so the expected result is string1 = test string2 = @me
a code will be something like this
func test(string: String) {
var mString = string
var cuttedString = mString.cutFrom("@")
print(mString)
print(cuttedString)
}
test(string: "test@me")
result:
test
@me