Skip to content

Commit 5e2fa73

Browse files
committed
Initial commit
0 parents  commit 5e2fa73

File tree

15 files changed

+333
-0
lines changed

15 files changed

+333
-0
lines changed

.clang-format

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
BasedOnStyle: WebKit
3+
PointerAlignment: Right

.editorconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
root = true
2+
3+
[*]
4+
charset = utf-8
5+
end_of_line = lf
6+
indent_size = 4
7+
tab_width = 4
8+
indent_style = space
9+
max_line_length = 120
10+
insert_final_newline = true
11+
trim_trailing_whitespace = true

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
* text=auto
2+
* eol=lf

.gitignore

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
.idea
2+
.vscode
3+
.vs
4+
5+
.env*
6+
*.d
7+
*.o
8+
*.ko
9+
*.obj
10+
*.elf
11+
*.ilk
12+
*.map
13+
*.exp
14+
*.gch
15+
*.pch
16+
*.lib
17+
*.a
18+
*.la
19+
*.lo
20+
*.dll
21+
*.so
22+
*.so.*
23+
*.dylib
24+
*.exe
25+
*.out
26+
*.app
27+
*.i*86
28+
*.x86_64
29+
*.hex
30+
*.dSYM/
31+
*.su
32+
*.idb
33+
*.pdb
34+
*.mod*
35+
*.cmd
36+
.tmp_versions/
37+
modules.order
38+
Module.symvers
39+
Mkfile.old
40+
dkms.conf
41+
*~
42+
.fuse_hidden*
43+
.directory
44+
.Trash-*
45+
.nfs*
46+
cmake-build-*
47+
CMakeLists.txt.user
48+
CMakeCache.txt
49+
CMakeFiles
50+
CMakeScripts
51+
Testing
52+
Makefile
53+
cmake_install.cmake
54+
install_manifest.txt
55+
compile_commands.json
56+
CTestTestfile.cmake
57+
_deps
58+
Thumbs.db
59+
Thumbs.db:encryptable
60+
ehthumbs.db
61+
ehthumbs_vista.db
62+
*.stackdump
63+
[Dd]esktop.ini
64+
$RECYCLE.BIN/
65+
*.cab
66+
*.msi
67+
*.msix
68+
*.msm
69+
*.msp
70+
*.lnk
71+
.DS_Store
72+
.AppleDouble
73+
.LSOverride
74+
Icon
75+
._*
76+
.DocumentRevisions-V100
77+
.fseventsd
78+
.Spotlight-V100
79+
.TemporaryItems
80+
.Trashes
81+
.VolumeIcon.icns
82+
.com.apple.timemachine.donotpresent
83+
.AppleDB
84+
.AppleDesktop
85+
Network Trash Folder
86+
Temporary Items
87+
.apdisk

CMakeLists.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
cmake_minimum_required(VERSION 3.23)
2+
project(leetcode)
3+
4+
add_subdirectory(lgc)
5+
add_subdirectory(parentheses)
6+
add_subdirectory(remove-duplicates-from-sorted)

_templates/c/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
set(CMAKE_C_STANDARD C90)
2+
3+
add_executable(leetcode_c main.c)

_templates/c/main.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#include <stdio.h>
2+
#include <stdlib.h>
3+
#include <string.h>
4+
5+
int main(void)
6+
{
7+
return 0;
8+
}

_templates/cpp/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
set(CMAKE_CXX_STANDARD 17)
2+
3+
add_executable(leetcode_cpp main.cpp)

_templates/cpp/main.cpp

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#include <iostream>
2+
#include <vector>
3+
4+
using namespace std;
5+
6+
template <typename Arg, typename... Args>
7+
void print(Arg &&arg, Args &&...args)
8+
{
9+
std::cout << std::forward<Arg>(arg);
10+
((std::cout << ' ' << std::forward<Args>(args)), ...);
11+
}
12+
13+
int main()
14+
{
15+
print("Hello", "Andy");
16+
return 0;
17+
}

lgc/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
set(CMAKE_C_STANDARD 99)
2+
3+
add_executable(lgc main.c)

0 commit comments

Comments
 (0)