Resources:
cp-algorithms
saisumit
implementation
CF-blog
Good blogs
Implementation:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode...
Showing posts with label Spoj. Show all posts
Showing posts with label Spoj. Show all posts
CLOPPAIR - Closest Point Pair
problem link: CLOPPAIR
Topic: Closest Point Pair
Implementation:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn...
FACT0 - Integer Factorization (15 digits)
FACT0 - Integer Factorization (15 digits)
টপিকঃ প্রাইম ফ্যাক্টর
হিন্টঃ সিভ দিয়ে করলে টাইম লিমিট, নরমালি করতে হবে। প্রথমে x = ২ দিয়ে যতবার যায় ভাগ তারপর ৩ দিয়ে , এরপর ৫ দিয়ে...
যখন x*x >N হয়ে যাবে তখন লুপটা ব্রেক হবে।
এরপর শেষে সংখ্যাটি ১ এর চেয়ে বড় থাকলে ওইটা একটা প্রাইম নাম্বার হবে, আর প্রতিবার ভাগ করার সময় একটা কাউন্ট রাখবো...
PON - Prime or Not (Miller Robin)
PON - Prime or Not
Topic: Miller Robin
Resource:
Primality Test | Set 3 (Miller–Rabin)
Miller Robin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below....
CEQU - Crucial Equation
CEQU - Crucial Equation
Topic: Linear Diophantine Equation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
...
INVCNT - Inversion Count
INVCNT - Inversion Count
Topic: BIT
This file contains bidirectional Unicode text that may be interpreted...
TOPOSORT - Topological Sorting
TOPOSORT - Topological Sorting
Topic: Topological Sorting
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn...
SUBXOR - SubXor
SUBXOR - SubXor
Subarray Xor
Topic: Trie Tree
Explanation
Solution 01:
//copy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
...