Skip to content

About

This consists all my cp practice codes

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

40 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

My CP Practice Codes

This is my personal practice code collection for DSA and competitive programming. I saved whatever I did while learning and solving problems here.

You can clone this repository, study the code, add your own solutions, and change anything to improve it.

Repository Structure

  • 1100.cpp, 800_900.cpp, 900_1000.cpp — rating-based practice from CP31 or similar problem lists.
  • april.cpp, june.cpp, junebooster.cpp — monthly contest/practice session files.
  • bitmasking.cpp — bitmask DP and subset technique practice.
  • cses.cpp — some solutions for CSES problems.
  • digitdp.cpp — digit DP and state-based digit dynamic programming.
  • dp.cpp — dynamic programming practice examples.
  • graphalgos.cpp — general graph algorithm templates and solutions.
  • graphproblem.cpp — graph problem practice and experiments.
  • leetcode.cpp — LeetCode practice solutions.
  • linkedlist.cpp — linked list problems and utilities.
  • math.cpp — math and number theory practice.
  • prefix.cpp — prefix/suffix arrays, sums, and range utilities.
  • rerootdp.cpp — rerooting DP on trees.
  • segment.cpp — segment tree implementations.
  • slidingwindow.cpp — sliding window pattern solutions.
  • sparsetable.cpp — sparse table and range min/max queries.
  • trees.cpp — tree algorithms, traversals, and tree DP.
  • tempCodeRunnerFile.cpp — temporary test or scratch code.
  • hints.txt — notes and reminders for common techniques and patterns.

How to Use

  1. Clone this repo.
  2. Browse the .cpp files and learn from the code.
  3. Add your own problems or improve existing files.
  4. Compile and run each file locally.

What You Can Do

  • Study the code and learn how I solved problems.
  • Add new practice files for problems you solve.
  • Improve existing code with better algorithms or clearer comments.
  • Rename files if you want a different organization.

Notes

The hints.txt file has quick reminders for common ideas:

  • prefixmin, prefixmax, suffixmin, suffixmax
  • prefixsum, suffixsum
  • Use segment tree or sparse table for range queries.
  • For minimizing operations using multiply/divide, think about Dijkstra-like search or brute force.
  • Try to identify independent conditions and use prefix min/max where possible.

License

This is my practice collection. Use it for learning, copying, or improving your own code.

About

This consists all my cp practice codes

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages