In reply to janudeep3:
You can always make an assignment to a string variable as a whole, and the target variable gets sized to hold the string (e.g.
s2=s1; or
s2=“Hello”;). The problem already mentioned with your original code is that you were trying to write to select individual characters of a string that had not been sized yet. So it was treated as an out of bounds select and nothing happens.