Original Post
I am a CS student, I have long been writing C&C++ mixing codes. I mean I use C++ compiler such as VS2008, but actually I am not good at OOP, so I just write C-like codes using C++. Many times I define a class and soon I will feel the design is bad, making the problem more complex. Sometimes I define a lot interfaces today and change all my minds tomorrow and re-write them all.
So finally I don't want to struggle any more. I know C grammar pretty well, so I think I'd better just use pure C, forgetting the C++ features. These days I am trying to write a pure C program, maybe thousonds lines of codes. A problem I met is that, I have been used to use STL data structure such as vector for a long time, but C doesn't have STL. I tried to write some general data structure like linked list, using function pointers to apply general operations. But soon I found it's not so easy to be general.
So I want to know how does professional C programmer write their daily codes? For example, when a linked list is used to organize some data, will you directly operate the pointer to next node in the application's algorithm, or will make an abstraction to hide the details of linked list?
Thanks for your time.
So finally I don't want to struggle any more. I know C grammar pretty well, so I think I'd better just use pure C, forgetting the C++ features. These days I am trying to write a pure C program, maybe thousonds lines of codes. A problem I met is that, I have been used to use STL data structure such as vector for a long time, but C doesn't have STL. I tried to write some general data structure like linked list, using function pointers to apply general operations. But soon I found it's not so easy to be general.
So I want to know how does professional C programmer write their daily codes? For example, when a linked list is used to organize some data, will you directly operate the pointer to next node in the application's algorithm, or will make an abstraction to hide the details of linked list?
Thanks for your time.