Contents:
1. Direct Address Table
2. Hashing
3. Characteristics of a good hash function
4. Collision Resolution using Chaining and Probing
5. Static vs Dynamic Hashing
6. Extendible Hashing
7. B+ tree vs Hashing
Trie Data Structure
LINK: https://leetcode.com/tag/trie/
Easy:
1. Longest Word in Dictionary
Medium:
1. Count Substrings That Differ by One Character
2. Replace Words
3. Top K Frequent Words
4. Maximum XOR of Two Numbers in an Array
5. Map Sum Pairs
Hard:
1. Concatenated Words
2. Word Search II
The Key Difference between a List and a Tuple. The main difference between lists and a tuples is the fact that lists are mutable whereas tuples are immutable. A mutable data type means that a python object of this type can be modified. Let's create a list and assign it to a variable.
Trie Data Structure
LINK: https://leetcode.com/tag/trie/
Easy:
1. Longest Word in Dictionary
Medium:
1. Count Substrings That Differ by One Character
2. Replace Words
3. Top K Frequent Words
4. Maximum XOR of Two Numbers in an Array
5. Map Sum Pairs
Hard:
1. Concatenated Words
2. Word Search II
The Key Difference between a List and a Tuple. The main difference between lists and a tuples is the fact that lists are mutable whereas tuples are immutable. A mutable data type means that a python object of this type can be modified. Let's create a list and assign it to a variable.
Merge sort is a sorting technique based on divide and conquer technique. With worst-case time complexity being Ο(n log n), it is one of the most respected algorithms.
Merge sort first divides the array into equal halves and then combines them in a sorted manner.
This presentation is all about various built in
datastructures which we have in python.
List
Dictionary
Tuple
Set
and various methods present in each data structure
Infix to Postfix Conversion Using StackSoumen Santra
Infix to Postfix Conversion Using Stack is one of the most significant example of application of Stack which is an ADT (Abstract Data Type) based on LIFO concept.
Queues
a. Concept and Definition
b. Queue as an ADT
c. Implementation of Insert and Delete operation of:
• Linear Queue
• Circular Queue
For More:
https://github.com/ashim888/dataStructureAndAlgorithm
http://www.ashimlamichhane.com.np/
Merge sort is a sorting technique based on divide and conquer technique. With worst-case time complexity being Ο(n log n), it is one of the most respected algorithms.
Merge sort first divides the array into equal halves and then combines them in a sorted manner.
This presentation is all about various built in
datastructures which we have in python.
List
Dictionary
Tuple
Set
and various methods present in each data structure
Infix to Postfix Conversion Using StackSoumen Santra
Infix to Postfix Conversion Using Stack is one of the most significant example of application of Stack which is an ADT (Abstract Data Type) based on LIFO concept.
Queues
a. Concept and Definition
b. Queue as an ADT
c. Implementation of Insert and Delete operation of:
• Linear Queue
• Circular Queue
For More:
https://github.com/ashim888/dataStructureAndAlgorithm
http://www.ashimlamichhane.com.np/
In this chapter we will analyze more complex data structures like dictionaries and sets, and their implementations with hash-tables and balanced trees. We will explain in more details what hashing and hash-tables mean and why they are such an important part of programming. We will discuss the concept of "collisions" and how they might happen when implementing hash-tables. Also we will offer you different types of approaches for solving this type of issues. We will look at the abstract data structure set and explain how it can be implemented with the ADTs dictionary and balanced search tree. Also we will provide you with examples that illustrate the behavior of these data structures with real world examples.
At the beginning, the number of elements in a set of numbers to be stored in a computer system used to be not so large or having a wide range. Then, using a
simple table T [0, 1, ..., m − 1]called, direct-address table, could be used to store those numbers. As the situation became more and more complex, and a new idea came to be:
Definition
An associative array, map, symbol table, or dictionary is an abstract data type composed of a collection of tuples {(key, value)}
This can bee seen in the example of dictionaries in any spoken language. The problem became more complex when the range of the possible values for the
keys at the tuples became unbounded. Therefore a new type of data structure is needed to avoid the sparsity problem in the data, the hash table.
This slide explains the conversion procedure from ER Diagram to Relational Schema.
1. Entity set to Relation
2. Relationship set to Relation
3. Attributes to Columns, Primary key, Foreign Keys
1. What is Entity Relationship Model
2. Entity and Entity Set
3. Relationship and Relationship Set
4. Attributes and it's kinds
5. Participation Constraints and Mapping Cardinality
6. Aggregation, Specialization, and Generalization
7. Some Sample ERD models
This note includes the followings:
- Database Create, Drop Operations
- Database Table Create, Drop Operations
- Database Table Alter Operation
- Data insertion
- Data deletion
- Existing data update
- Searching data from data table (showing all record, specific columns, specific rows, column aliasing, sorting data, limiting data, distinct data)
- Aggregate functions
- Group by clause
- Having clause
- Types of table joins
- Table aliasing, Inner Join, Left/Right Join, Self Join
- Subquery operation (scalar subquery, column subquery, row subquery, correlated subquery, derived table)
This note contains some sample MySQL query practices based on the HR Schema database. The practice sections are from the following categories:
- DDL statements
- Basic Select statements
- Aggregate operations
- Join operations
This lecture slide contains:
- Difference between FA, PDA and TM
- Formal definition of TM
- TM transition function and configuration
- Designing TM for different languages
- Simulating TM for different strings
This slide contains,
1) Some terminologies like yields, derives, word, derivation
2) Leftmost and Rightmost derivation
3) Ambiguity checking
4) Parse tree generation and ambiguity checking
How to Make a Field invisible in Odoo 17Celine George
It is possible to hide or invisible some fields in odoo. Commonly using “invisible” attribute in the field definition to invisible the fields. This slide will show how to make a field invisible in odoo 17.
This is a presentation by Dada Robert in a Your Skill Boost masterclass organised by the Excellence Foundation for South Sudan (EFSS) on Saturday, the 25th and Sunday, the 26th of May 2024.
He discussed the concept of quality improvement, emphasizing its applicability to various aspects of life, including personal, project, and program improvements. He defined quality as doing the right thing at the right time in the right way to achieve the best possible results and discussed the concept of the "gap" between what we know and what we do, and how this gap represents the areas we need to improve. He explained the scientific approach to quality improvement, which involves systematic performance analysis, testing and learning, and implementing change ideas. He also highlighted the importance of client focus and a team approach to quality improvement.
We all have good and bad thoughts from time to time and situation to situation. We are bombarded daily with spiraling thoughts(both negative and positive) creating all-consuming feel , making us difficult to manage with associated suffering. Good thoughts are like our Mob Signal (Positive thought) amidst noise(negative thought) in the atmosphere. Negative thoughts like noise outweigh positive thoughts. These thoughts often create unwanted confusion, trouble, stress and frustration in our mind as well as chaos in our physical world. Negative thoughts are also known as “distorted thinking”.
2024.06.01 Introducing a competency framework for languag learning materials ...Sandy Millin
http://sandymillin.wordpress.com/iateflwebinar2024
Published classroom materials form the basis of syllabuses, drive teacher professional development, and have a potentially huge influence on learners, teachers and education systems. All teachers also create their own materials, whether a few sentences on a blackboard, a highly-structured fully-realised online course, or anything in between. Despite this, the knowledge and skills needed to create effective language learning materials are rarely part of teacher training, and are mostly learnt by trial and error.
Knowledge and skills frameworks, generally called competency frameworks, for ELT teachers, trainers and managers have existed for a few years now. However, until I created one for my MA dissertation, there wasn’t one drawing together what we need to know and do to be able to effectively produce language learning materials.
This webinar will introduce you to my framework, highlighting the key competencies I identified from my research. It will also show how anybody involved in language teaching (any language, not just English!), teacher training, managing schools or developing language learning materials can benefit from using the framework.
Unit 8 - Information and Communication Technology (Paper I).pdfThiyagu K
This slides describes the basic concepts of ICT, basics of Email, Emerging Technology and Digital Initiatives in Education. This presentations aligns with the UGC Paper I syllabus.
How to Create Map Views in the Odoo 17 ERPCeline George
The map views are useful for providing a geographical representation of data. They allow users to visualize and analyze the data in a more intuitive manner.
The Indian economy is classified into different sectors to simplify the analysis and understanding of economic activities. For Class 10, it's essential to grasp the sectors of the Indian economy, understand their characteristics, and recognize their importance. This guide will provide detailed notes on the Sectors of the Indian Economy Class 10, using specific long-tail keywords to enhance comprehension.
For more information, visit-www.vavaclasses.com
Read| The latest issue of The Challenger is here! We are thrilled to announce that our school paper has qualified for the NATIONAL SCHOOLS PRESS CONFERENCE (NSPC) 2024. Thank you for your unwavering support and trust. Dive into the stories that made us stand out!
The Art Pastor's Guide to Sabbath | Steve ThomasonSteve Thomason
What is the purpose of the Sabbath Law in the Torah. It is interesting to compare how the context of the law shifts from Exodus to Deuteronomy. Who gets to rest, and why?
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
Thesis Statement for students diagnonsed withADHD.ppt
DBMS 9 | Extendible Hashing
1. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Hashing
Direct-address table >>
Universe of keys, U = { 0, 1, … … , m-1 } where m is not too large.
Uses a direct-address table, denoted by T [0..m-1] in which each slot corresponds to a key in the universe U.
An element with key k is stored in slot k.
Search, Insert, Delete operation takes O(1) time.
Storage requirement: Θ(|U|)
Problems:
If the universe U is large, storing a table T of size |U| may be impractical, or even impossible, given the
memory available on a typical computer.
Furthermore, the set K of keys actually stored may be so small relative to U that most of the space
allocated for T would be wasted.
Hash Table >>
Storage requirement: Θ(m)
Average search time: O(1)
With hashing, an element with key k is stored in slot h(k), we use hash function h to compute the slot from the
key k.
Uses a hash table T [0..m-1] where h maps U to the slot number,
h : U -> { 0, 1, … , m-1 }
Hash function reduces the range of array indices and hence the size of the array. Instead of a size of |U|, the
array can have size m.
2. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Good Hash Function Characteristics >>
Satisfies the assumption of simple uniform hashing: each key is equally likely to hash to any of the m slots,
independently of where any other key has hashed to.
Keys that are close in some sense must yield hash values that are far apart, independent of any patterns that
might exist in the data.
Number of collisions should be less while placing the data in the hash table.
Average search time: O(1)
Collision Resolution >>
1. Chaining -> Open Hashing/Separate Chaining :
Insertion:
2 keys / bucket
3. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Deletion:
2. Probing -> Closed Hashing/Open Addressing:
Linear Probing:
Auxiliary hash function: h’
: U -> { 0, 1, … , m-1 }
Hash function: h(k, i) = (h’(k) + i) mod m; i = 0,1, … , m-1
First tries to insert into h’(k), if collusion found then search the next available slots for insertion.
Here, 1 key/bucket, auxiliary hash fn: h’(k) = k % 7, hash fn: h(k, i) = ( (k%7) + i ) % 7 ; i = 0, 1 , … , 6
4. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Quadratic Probing:
Hash function: h(k, i) = ( h’(k) + c1* i + c2*i2
) mod m; i = 0, 1, … , m-1
Here, 1 key/bucket, c1 = 0 and c2 = 1, auxiliary hash fn: h’(k) = k % 7, hash fn: h(k, i) = ( (k%7) + i2
) % 7
Double Hashing:
Hash function: h(k, i) = ( h1(k) + i*h2(k) ) mod m ; i = 0, 1, … , m-1
Let, 1 key/bucket, h1(k) = k % 7 , h2(k) = 5 – ( k % 5), hash function: h(k, i) = ( h1(K) + i*h2(k) ) % 7
8 8
5. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Static Hashing >>
The hash tables we have examined so far are called static hash tables, because the number of bucket addresses never
changes that is hash table size is fixed.
Example: Chaining and Probing.
Dynamic Hashing >>
The hash table size is allowed to vary so that it can add/remove data buckets depending on the number of records.
Two types:
Extensible Hashing
Linear Hashing
Extensible Hashing >>
There is an array of pointers to buckets.
The array of pointers can grow. Its length is always a power of 2, so in a growing step the number of buckets
doubles.
There doesn’t have to be a data block for each bucket. Certain buckets can share a block if the total number of
records in those buckets can fit in the block.
The hash function h computes for each key a sequence of k bits for some large k, say 32.
The bucket numbers will at all times use some smaller number of bits, say i bits, from the beginning of this
sequence of k bits. (i.e. 2i
maximum no of entries).
The number(j) appearing in the nub of each buckets, indicates how many bits of the hash function’s sequence is
used to determine membership of records in this block.
Online Simulator Link: https://devimam.github.io/exhash/
Insertion:
▸ Inserting 1010
6. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Final structure:
7. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
▸ Inserting 0111 , 0000
8. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Final structure:
▸ Inserting 1001
9. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Final structure:
B+
tree vs Hashing >>
▸ Hashing good for given key values, no need to access index structure
Example:
SELECT * FROM Sells WHERE price = 20;
▸ B+ Trees and conventional indexes good for range queries:
Example:
SELECT * FROM Sells WHERE price > 20;
10. Mohammad Imam Hossain, Lecturer, Dept. of CSE, UIU. Email: imambuet11@gmail.com
Practices:
1. Suppose that we are using extendable hashing on a file that contains records with the following search key
values:
2, 3, 5, 7, 11, 17, 19, 23, 29, 31
Show the extendable hash structure for this file if the hash function is h(x) = x mod 8 and buckets can hold three
records.
2. Suppose you have a file that contains records with the following searck key values:
42, 71, 43, 70, 12, 22, 91, 62, 53, 82
Now build an Extensible hash index structure by inserting these search keys sequentially where the hash
function is h(search-key) = (reverse the digits of the search key) mod 8 and each bucket can hold at most three
records.
3. Consider the Hash Function h(x) = x mod 8 and the given search keys:
0, 7, 1, 2, 3, 11, 13, 22
Insert the search keys one by one into an extensible hash structure using the given hash function where each
bucket can contain at most 3 keys.