Truncate A Dynamically Allocated String | C Programming Example

preview_player
Показать описание
Рекомендации по теме
Комментарии
Автор

Hey, I'm new to this c++ programing stuff. I'm currently taking cis 6 in college which is in intro to c++ but it has been really hard for me. I really like this programing stuff, but it's been hard for me to grasp the concepts that are being taught to me. Do you have any recommendations on how to keep this information in my brain and to actually understand it better?

bkly_
Автор

hi sir understand able explanation . I have a doubt of using tydef with array of pointer how to use typedef with array of pointer s can you pls explain .... I am not able to understand how to use type def exactly in this situation.. thank you

ramakrishna
Автор

Hey :) first of all thnx a lot for this Videos and the Explanation🤗
i have two questions, why did we use strcpy in this example? couldn't we initialize so: char *string = "it works on my machine." ?
and in this case we did knew at which Index comes the '\0' but what it if we didn't know it?

muhisaleh
Автор

Thanks so much for addressing my question 👍. Really nice to see n+1 being used to determine size, so much more intuitive.
This of course brings up another question: do malloc and realloc always take bytes, regardless of the machine/architecture?

qcnck
Автор

Bro 🎉
Plse continue the Design pattern playlist in c++ -> I want Observer and factory method design Pattern

looserarun
join shbcf.ru