CPP – Ignore Case To Compare String

STL Algorithm std::lexicographical_compare is an algorithm which can be used to compare string lexicographically.We can give our comparing function to make it work without pay attention to capital and small letter. C++ template constexpr bool lexicographical_compare( InputIt1 first1, InputIt1 last1, InputIt2 first2, InputIt2 last2, Compare comp ); Example: C++ #include Read more…

CPP – Unique Copy In STL

std::unique_copy is an algorithm which can be used to copy elements without duplicating objects in adjacent locations. template< class InputIt, class OutputIt > OutputIt uniquecopy( InputIt first, InputIt last, OutputIt dfirst ); Usage example: C++ #include #include #include #include int main() { std::string s1 = “This is a story about Read more…

VTK – vtkGraphLayoutView Example

vtkRandomGraphSource can be used to create a random graph which includes points and edges. vtkGraphLayoutView is a vtkRenderView which has its own renderer and iterator, we can use it to display graph view. from vtk import * # create a random graph source = vtkRandomGraphSource() source.SetNumberOfVertices(100) source.SetNumberOfEdges(110) source.StartWithTreeOn() #create a Read more…

JIT Debugger Tool Drmingw

The introduction of Just-in-Time (JIT) debugger tool drmingw: https://vroby.ddns.net/Public/sdlBasic/MinGW/doc/drmingw/drmingw.html It’s very easy to install this tool. We can download from the internet and unzip it: It’s necessary to put the directory of the tool bin in the environment variable Path on windows OS. After that, we can run drmingw.exe by Read more…

Tex To PDF
: convert the Latex file which suffix is tex to a PDF file

X