Algorithms and data structures don't care about languages.
A sort function written in C, C++, Python, Javascript, blah, yawn, whatever is still a sort function.
> How to use multiple languages like c++ and HTML in a common project.
You use whichever language is best suited to the task.
A valid HTML document - Free tutorial to learn HTML and CSS
Your browser doesn't give a damn whether the server at the other end uses C, C++ or whatever.
So long as a valid HTML document gets transmitted down the socket connection, you're free to do whatever you want at the other end.