Classical problem analysis of data structure and algorithm Java language description PDF

Source: Internet
Author: User
Tags bitwise


: Network Disk Download

Introduction to Java as a description language, the basic knowledge of data structure and algorithm is introduced. The book combines the engineering practice of the enterprise to refine the teaching content, especially the confusing problems in the data structure, and puts forward different solutions to each problem. This book is an excellent material for the data structure. Directory Translator sequence
Objective
Chapter 1th Introduction 1
1.1 Variables 1
1.2 Data type 1
1.3 Data Structure 2
1.4 Abstract Data Type 2
1.5 What is algorithm 3
1.6 Why algorithm analysis is required 3
1.7 Purpose of the algorithm analysis 3
1.8 What is run time analysis 4
1.9 How to compare algorithms 4
1.10 What is growth rate 4
1.11 Common Growth rate 4
1.12 Types of Analysis 5
1.13 Asymptotic representation 6
1.14 Large O-notation 6
1.15ω notation 7
1.16θ notation 8
1.17 Important Notes 9
1.18 Why is it called Asymptotic analysis 9
1.19 Asymptotic analysis Guide 9
1.20 properties of the asymptotic representation 11
1.21 Common logarithm and summation formulas 11
1.22 main theorem of division and rule 12
1.23 related problems of the principal theorem of division and rule 12
1.24 problem scale reduction and recursive solution main theorem 13
1.25 Problem size reduction and recursive solution to the main theorem variant 13
1.26 methods of guessing and confirming 14
1.27 Split Analysis 15
1.28 problems related to algorithmic analysis 15
Chapter 2nd recursion and backtracking 28
2.1 Introduction 28
2.2 What is recursion 28
2.3 Why use recursion 28
2.4 Format of the recursive function 28
2.5 Recursion and memory (visualization) 29
2.6 Recursion and Iteration 30
2.7 Recursive Description 30
2.8 Classic use Case for recursive algorithms 30
2.9 Related issues with recursion 31
2.10 What is backtracking 32
2.11 Classic use case for backtracking algorithms 32
2.12 Backtracking related issues 32
The 3rd Chapter list 34
3.1 What is linked list 34
3.2 Linked list abstract data type 34
3.3 Why use linked list 35
3.4 Overview of Arrays 35
3.5 Comparison of linked lists, arrays, and dynamic arrays 36
3.6 Unidirectional Link List 36
3.7 Doubly linked list 41
3.8 Circular Link List 46
3.9 A storage-efficient bidirectional list 51
3.10 Loose Linked List 52
3.11 related issues with linked list 55
The 4th Chapter Stack 72
4.1 What is stack 72
4.2 How to use the stack 72
4.3 stack abstract data type 73
4.4 Exception 73
4.5 Application 73
4.6 Implementation 73
4.7 Stacks of various implementation methods comparison 77
4.8 Stack related issues 78
5th. Queue 98
5.1 What is a queue 98
5.2 How to use queue 98
5.3 Queue abstract data Type 99
5.4 Exception 99
5.5 Application 99
5.6 Implementation 99
5.7 Related issues with Queues 104
6th Chapter Tree 110
6.1 What is a tree 110
6.2 Terminology 110
6.3 Two fork Tree 111
6.4 Two cross-tree traversal 114
6.5 Universal tree (n Fork Tree) 135
6.6 Clues (no stack or no queue structure) binary Tree Traversal 141
6.7 Expression Tree 147
6.8 Xor Tree 149
6.9 Two fork Search tree 150
6.10 Balanced binary Search tree 164
6.11AVL Tree 165
6.12 Other forms of the tree 178
6.12.1 Red and Black tree 178
6.12.2 Stretching Tree 179
6.12.3 Enhancement Tree 179
6.12.4 Scapegoat Tree 179
6.12.5 interval Tree 180
7th Priority Queue and heap 181
7.1 What is priority queue 181
7.2 Priority Queue ADT181
7.3 Application of the priority queue 182
7.4 Implementation of the priority queue 182
7.5 Heap and two fork heap 183
7.6 Two fork Pile 184
7.7 related issues with priority queue (heap) 190
The 8th chapter and check the collection ADT201
8.1 Introduction 201
8.2 Equivalence relation and equivalence class 201
8.3 and check set ADT202
8.4 Application 202
8.5 and check the tradeoff of ADT implementations 202
8.6 Fast Union implementation (slow find) 203
8.7 Fast Union implementation (FAST find) 206
8.8 Path Compression 208
8.9 Summary 209
8.10 Related issues of check set 209
The 9th Chapter diagram algorithm 211
9.1 Introduction 211
9.2 Terminology 211
9.3 Application of the figure 214
9.4 Representation of the figure 214
9.5 Graph Traversal 217
9.6 Topology sequencing 225
9.7 Shortest Path Algorithm 226
9.8 Minimum Spanning Tree 231
9.9 Graph algorithm related issues 235
10th Chapter Sort 256
10.1 What is sort 256
10.2 Why you need to sort 256
10.3 Sorted by Category 256
10.4 Other classification methods 257
10.5 Bubble Sort 257
10.6 Select Sort 258
10.7 Inserting sort 259
10.8 Hill Sort 261
10.9 Merge Sort 262
10.10 Heap Sort 264
10.11 Quick Sort 264
10.12 Tree Sort 266
10.13 Sorting algorithm Comparison 267
10.14 Linear Sorting algorithm 267
10.15 Counting Sort 267
10.16 barrels Sorted 268
10.17 Cardinality Sort 268
10.18 topology sequencing 269
10.19 External Sort 269
10.20 related issues with sorting 270
11th Chapter Find 279
11.1 What is find 279
11.2 Why do I need to find 279
11.3 Type of Lookup 279
11.4 Symbol table and hash 281
11.5 String Lookup Algorithm 281
11.6 related issues for finding 281
12th Chapter Selection Algorithm (median) 304
12.1 What is the selection algorithm 304
12.2 Sorting-based selection algorithm 304
12.3 Partitioning-based selection algorithm 304
12.4 Linear selection algorithm--median median algorithm 305
12.5 Finding K minimum elements in sort order 305
12.6 issues related to the selection algorithm 305
Chapter 13th Symbol Table 314
13.1 Introduction 314
13.2 What is a symbol table 314
13.3 implementation of the symbol table 315
13.4 Comparison of the implementation methods of the symbol table 315
14th Chapter Hash 317
14.1 What is hash 317
14.2 Why use Hash 317
14.3 Hash Table ADT317
14.4 example of a hash 317
14.5 part of the hash 319
14.6 Hash Table 319
14.7 hash function 319
14.8 Load factor 320
14.9 Conflicts 320
14.10 Conflict Resolution Technology 320
14.11 Separating link Method 320
14.12 Open Addressing Method 321
14.13 Comparison of conflict resolution Technologies 322
14.14 How the hash reaches the time complexity of O (1) 322
14.15 Hashing Technology 323
14.16 problem with hash table not applicable 323
14.17 Bloom Filter 323
14.18 Hashing related issues 325
15th Chapter String Algorithm 335
15.1 Introduction 335
15.2 String Matching algorithm 335
15.3 Brute Force method 336
15.4RobinKarp String Matching algorithm 336
15.5 algorithm of string matching based on finite automata 337
15.6KMP Algorithm 338
15.7BoyceMoore algorithm 342
15.8 data structures that store strings 342
15.9 hash Table implementation of string 342
15.10 string Two-fork search tree Implementation 343
15.11-Key Tree 343
15.12 three-prong search tree 345
15.13 Two forks search tree, key tree and three-fork search tree Comparison 349
15.14 suffix Tree 349
15.15 related issues with strings 353
The 16th chapter of algorithm Design Technology 361
16.1 Introduction 361
16.2 Category 361
16.3 Classification by implementation Method 361
16.4 classification By Design Method 362
16.5 other classifications 363
17th Greedy Algorithm 364
17.1 Introduction 364
17.2 definition of the greedy policy 364
17.3 elements of the greedy algorithm 364
17.4 Application range of greedy algorithm 365
17.5 advantages and disadvantages of the greedy algorithm 365
17.6 application of the greedy algorithm 365
17.7 Greedy Thoughts 365
17.8 issues related to greedy algorithms 368
Chapter 18th divide and conquer algorithm 375
18.1 Introduction 375
18.2 definition of a divide-and-conquer strategy 375
18.3 scope of application of the method of Division 375
18.4 graphical description of the divide-and-conquer method 375
18.5 divide and conquer thought 376
18.6 Main theorem 377
18.7 application of divide-and-conquer method 377
18.8 related issues of division and Administration 378
The 19th Chapter Dynamic programming algorithm 390
19.1 Introduction 390
19.2 definition of dynamic planning Strategy 390
19.3 nature of the dynamic planning Strategy 390
19.4 scope of application of dynamic planning 390
19.5 How to implement dynamic programming 391
19.6 Examples of dynamic programming algorithms 391
19.7 Dynamic Planning Ideas 391
19.8 issues related to dynamic planning 396
20th Chapter Complexity Type 425
20.1 Introduction 425
20.2 polynomial/exponential time 425
20.3 definition of a decision question 426
20.4 decision-making process 426
20.5 definition of the complexity type 426
20.6 Type of complexity 426
20.7 return about 428
20.8 issues related to complexity types 430
21st Chapter 433
21.1 Introduction 433
Use of 21.2-bit operations 433
21.2.1 Bitwise AND Operation 433
21.2.2 Bitwise OR Operation 434
21.2.3 Bitwise XOR OR Operation 434
21.2.4 bitwise LEFT SHIFT operation 434
21.2.5 bitwise RIGHT SHIFT operation 434
21.2.6 bitwise complement Operation 434
21.2.7 detect if the K bit is set to 434
21.2.8 k Position Bit 435
21.2.9 K-Position 435
21.2.10 switching K-bit 435
21.2.11 Toggle value 1, right-most 435
21.2.12 Isolation value 1, right-most 435
21.2.13 Isolation value 0, right-most 435
21.2.14 Check if a number is a power of 2 436
21.2.15 multiply a number by a power of 2 to 436
21.2.16 divides a number by a power of 2 to 436
21.2.17 find modulo 436 for a given operand
21.2.18 Invert binary number 436
21.2. Count of 19-bit value 1 436
21.2.20 Creating a mask at the end bit 0 437
21.2.21 switching parity bit 438
21.2.22 do not use Division to calculate averages 438
21.3 Other programming issues 438
Reference 442 view all ↓ Preface/Preface I know that many readers tend not to read the preface, but it is highly recommended that you at least look at the preface of the book because the preface is different.
The main purpose of this book is not to provide theorems and proofs about data structures and algorithms. The model used in this book is to use different complexities to improve the solution of the problem (for each problem, you will find multiple solutions with different complexity and reduced complexity). Basically, this idea is to enumerate all possible solutions to a problem. In this way, even if you encounter a new problem, it can also show you how to think about all possible solutions to the problem. This book is useful for readers who are preparing for an interview, taking a selection test, and interviewing on campus.
As a job seeker, if you can read the book in full and get a good grasp of the contents of the book, I believe you will calmly face the interviewer, which is the purpose of this book. If you are reading this book as a teacher, you will be able to improve the quality of your teaching in a simple way, and students will be delighted to choose a degree in computer Science/information technology.
As a student preparing for a computer science/Information Technology Professional selection exam, this book covers all the necessary topics in full and in detail, and in writing this book is focused on helping the students who are preparing the exams.
This book is very useful for both students and postgraduates who are studying for an engineering degree. In all the chapters, you will find that the book emphasizes the problem and its analysis rather than the elaboration of the theory. Each chapter will first explain the necessary theoretical basis, and then give the problem set. There are about 700 algorithmic problems and corresponding solutions in the book.
For many problems, this book provides several solutions with different complexities. We start with the brute force method and gradually introduce a good solution to the problem. For each problem, we try to know the runtime and memory space required by the algorithm.
Readers are advised to read the book thoroughly at least once in order to fully understand all the topics. In the subsequent readings, you can select any chapter to read and reference directly. Even after enough inspections, it is inevitable that there will be small flaws in the book. If any such errors are found, the www.CarrerMonk.com website will be updated, so please keep an eye on this website in order to be aware of any errata, new issues and workarounds. In addition, please provide valuable advice to [email protected].
I wish you every success. I'm sure you'll find this book very useful.
Thanks to my parents, what they have done for me is not measurable, it is their selfless love, the stable growth environment and persistent traditional values that taught me to praise and embrace life. They are good parents and role models in the world, and they make me understand that faith, diligence and determination can make anything possible!
The writing of this book has been helped by a lot of people, and without their help the book is impossible to complete. Thank them for their efforts to improve the final draft of this book. It should be noted that I have done my best to correct the errors identified by the reviewer and to describe the various protocols and mechanisms accurately. I am personally responsible for any other errors that appear in the book.
First of all, thank those who have helped me through the writing process, thank all those who have given me support, thank all those who have participated in the discussion, reading, writing and giving valuable comments, and thank all those who have allowed me to quote their comments and assist me in editing, proofreading and designing the book. In particular, I would like to thank the following people:
Mohan Mullapudi, Indian Institute of Technology, Mumbai, architect, datarpm pvt.ltd. Navin Kumar Jaiswal, Senior consultant, Juniper Networks Inc. Kishore Kumar Jinka, Indian Institute of Technology Mumbai A.vamshi Krishna, Indian Polytechnic Institute Kanpur, Mentor Graphics Inc. Hirak Chatterjee,yahoo Inc. Kondrakunta Murali Krishna, Bachelor of Science, technical director, HCL Chaganti Siva Rama Krishna Prasad, founder, Stockmonks Pvt.ltd. Naveen Valsakumar, co-founder, Notionpress Pvt.ltd. Ramanaiah, lecturer, Dragon Tree Institute of Technology, MLG, thanked Guntur Vikas College director Y.v.gopala Krishna Murthy professor, Ayub Khan (Ace Engineering School), T.R.C. Bose (former director of Aptransco), Ch.venkateswara Rao VNR Vignanajyothi (engineering School, Hyderabad), Ch.venkata Narasaiah (IPS), Yarapathineni Lakshmaiah (Manchikallu,gurazala), and all the kind people who helped me and my family during the project.
--NARASIMHA Karumanchi, Indian Institute of Technology, Bombay, Master of Science, Careermonk.com founder

: Network Disk Download

Classical problem analysis of data structure and algorithm Java language description PDF

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.