working for multiple data type as well as no limited length