Hi,
I need to write a program that splits a length of string to max 5 rows of 25 characters each. The problem is I need to delimit using space, dash, carat (stands for carriage return), backslash etc.
For example,
string= "Beddings/Carpets/Curtains/Cushions"
==> string1 = "Beddings/Carpets/"
string2 = "Curtains/Cushions"
string= "High Fidelity & Stereophonic Equipment-Dealers & Service"
==> string1 = "High Fidelity &"
string2 = "Stereophonic"
string3 = "Equipment-Dealers &"
string4 = "Service"
string= "Churches-Church Of Jesus Christ Of^Latter-Day Saints"
==> string1 = "Churches-Church Of"
string2 = "Jesus Christ Of"
string3 = "Latter-Day Saints"
Problem here is I'm not sure of the logic of the search I should use. Any ready-made codes or pointers are appreciated greatly!
I need to write a program that splits a length of string to max 5 rows of 25 characters each. The problem is I need to delimit using space, dash, carat (stands for carriage return), backslash etc.
For example,
string= "Beddings/Carpets/Curtains/Cushions"
==> string1 = "Beddings/Carpets/"
string2 = "Curtains/Cushions"
string= "High Fidelity & Stereophonic Equipment-Dealers & Service"
==> string1 = "High Fidelity &"
string2 = "Stereophonic"
string3 = "Equipment-Dealers &"
string4 = "Service"
string= "Churches-Church Of Jesus Christ Of^Latter-Day Saints"
==> string1 = "Churches-Church Of"
string2 = "Jesus Christ Of"
string3 = "Latter-Day Saints"
Problem here is I'm not sure of the logic of the search I should use. Any ready-made codes or pointers are appreciated greatly!