Giter VIP home page Giter VIP logo

cpplib's Introduction

cpplib

這個 repository 記錄了我練習寫 C++ 函式庫(library)的過程。每個項目是在不同時間撰寫的,而我在過程中持續改進自己的程式,因此不同項目的程式碼風格會有些微的不同。

目錄:

  • list - 使用 std::shared_ptr 做為 list node 的 doubly linked list
  • vector - 能自動增長 capacity 的 vector,記憶體分配均攤 O(1)
  • string - 模仿 std::string,支援 iostream 的 stream operator (>><<)
  • algorithm
    • sort
      • mergesort

Requirements

  • GCC v7.x or higher
  • Make

Build

The code can be compiled with the provided makefile using the standard make command.

make

Run

To run the code.

./main

Project Structure

.
├── README.md
├── main.cpp
├── makefile
├── src
│   ├── algorithm
│   │   └── sort.hpp
│   ├── list
│   │   └── list.hpp
│   ├── string
│   │   ├── string.cpp
│   │   └── string.hpp
│   └── vector
│       └── vector.hpp
└── test
    ├── list.hpp
    ├── string.hpp
    └── vector.hpp

cpplib's People

Contributors

lovesnowex avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.