I have an assignment where I have to convert a c++ like program to a c program.
If I have something like
class B {
int var;
int somefunction(){
some code here
}
}
it would get changed to
struct B{
int var;
}
int somefunction(){
some code here
}
Basically, I have to change class
to struct
every time I see it, and if there is a function I have to move it out outside the struct now.
What is the best approach to doing something like this? I get the theory behind this but not sure how to go about approaching it.