To add a value between the values in a string array

Asked 2 years ago, Updated 2 years ago, 25 views

I want to put a space between each string like the bottom, but I don't know what to do Elements can be reduced and stretched.
Help me, masters!

van = ["Ga"]

//The desired result ["Ga", "Na", "Da"]


Varm = ["Ga" "Na" "Da" "La" "Ma"]

//The desired result ["Ga", "Na", "Da", "La", "Ma"]

swift

2022-09-21 16:39

1 Answers

let characters = Array(n.joined(separator: " "));


2022-09-21 16:39

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.