changed constructor for static strings
replaced 'while(' with 'while ('