Skip to content

jgndev/cpp_dsa_templ

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DSA C++ Template

This repo is for quickly setting up a C++ project that uses CMake and GoogleTest.

It is intended for practice with the C++ language while doing Data Structures and
Algorithms problems like those found on leetcode.com

Instructions

1 - Clone the repo to a directory name of your choice.

git clone https://github.com/jgndev/dsa_cpp_templ example_problem

2 - Run the project init script project-init.sh

./project-init.sh

This creates a build directory and links compile-commands.json to the top level which helps LSPs work in editors like neovim.

Building

1 - Change directory into build

2 - Run make

Running tests

1 - Add your tests to tests/test_solution.cpp

2 - Change directory to build

3 - Run make to compile test_solution

4 - Run ./test_solution to run the tests.

About

c++ dsa template

Topics

Resources

License

Stars

Watchers

Forks