Giter Club home page Giter Club logo

coding-library's Introduction

Coding Library

By failed_coder

https://math.stackexchange.com/questions/2956889/how-many-number-of-integer-coordinates-exists-between-a-line-segment-including

no of trees with n labeled vertices is n^(n-2) https://en.wikipedia.org/wiki/Cayley%27s_formula

https://proofwiki.org/wiki/Sum_of_r%2Bk_Choose_k_up_to_n

Smallest Enclosing Circle https://codeforces.com/blog/entry/23554

a+b=aโŠ•b+2ร—(a and b)=(a or b)+(a and b)

Dilworth's theorem states that, in any finite partially ordered set, the largest antichain has the same size as the smallest chain decomposition

Set bits xor pairsum https://atcoder.jp/contests/abc091/submissions/11263481

Policy Based data structure OrderedSet

(Use as multiset) #include <ext/pb_ds/assoc_container.hpp> // Common file #include <ext/pb_ds/tree_policy.hpp> // Including tree_order_statistics_node_updat using namespace __gnu_pbds; typedef tree<ll, null_type, less_equal, rb_tree_tag, tree_order_statistics_node_update> ordered_set;

order_of_key -> find element less than x find_order_by -> returns iterator to kth largest element counting from 0. lower bound works as upper bound

Normal set typedef tree<ll, null_type, less, rb_tree_tag, tree_order_statistics_node_update> ordered_set;

Fast Hash in cpp

const int RANDOM = chrono::high_resolution_clock::now().time_since_epoch().count(); struct chash { int operator()(int x) const { return x ^ RANDOM; }}; cc_hash_table<int, int, hash> cnt;

coding-library's People

Contributors

saikunocoda avatar vichitr avatar imgro0t avatar

Stargazers

Cenyue Zhang avatar GAURAV avatar Karthik Ramnath avatar Hardik Rana 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.