How to add to custom position in a string variable number of custom characters not using any loops? What is the most efficient way?
if(s.length() < width) { //add spaces
n = width - s.length();
s = (' '*n ) + s; // pseudo code
}