object oriented c codes added