Why this is giving error?
AND Also if I use β\0β in function instead of β\0β, It is also giving error.
Please help.
Why this is giving error?
Hey @cbcao263 using string wonβt be a good idea as a string act as an object , I would suggest you to declare character array.
Hereβs the code for reference. Hope this will help you 
Okayy Sir, Thanks.
But Isnβt char* arr and string are same thing?
Technically not @cbcao263, strings sometime fails some operations which character array donβt. So if you only have to read from an array , you can surely use string. But if you want to modify an array, always prefer to use characters array 
Okayyyy Sir,
Thanks Understood Now.
I hope Iβve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.