# leetcode-why **Repository Path**: Yoder_why/leetcode-why ## Basic Information - **Project Name**: leetcode-why - **Description**: leetcode刷题之旅 - **Primary Language**: Unknown - **License**: MulanPSL-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2022-06-30 - **Last Updated**: 2024-06-02 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # leetcode-why ## 目录结构 ``` leetcode-why |-- build |-- cmake:gtest配置 |-- include:使用库时需引用的头文件 |-- modules:库源码 | |-- include:库头文件 | |-- src:实现代码 |-- test:测试 |-- test_functions.hpp:测试用的公共函数 |-- main.cpp:准确度测试 ``` ### CMAKE_BUILD_TYPE Default: `Release`. Options: `Debug Release RelWithDebInfo MinSizeRel`. ```bash cmake .. -DCMAKE_BUILD_TYPE=Release ``` ## 使用leetcode-why库 ### 安装 Run `make install` to install our leetcode-why to the path. Then we can use `find_package(LEETCODE_WHY REQUIRED)` to find this lib in other project. Then we will get two `PATH`: `LEETCODE_WHY_LIBRARIES` and `LEETCODE_WHY_INCLUDE_DIR`. We can use `include_directory(${})` and `target_link_libraries(xxx ${})` to link this lib to an executable program.