MCPcopy Create free account

hub / github.com/anupam-kumar-krishnan/Competitive_Programming / functions

Functions2,161 in github.com/anupam-kumar-krishnan/Competitive_Programming

↓ 1 callersFunctiongetInvCount
DSA 450/Arrays/16.Count Inversions.cpp:9
↓ 1 callersMethodgetLen
()
DSA 450/Linked List/middle of linked list.java:32
↓ 1 callersMethodgetMax
(int arr[], int n)
All Algorithms/Sorting Algorithm/radix_sort.java:9
↓ 1 callersMethodgetMaxArea
Function to find largest rectangular area possible in a given histogram.
DSA 450/Stack/MaximumRectangularAreaInHistogram.cpp:57
↓ 1 callersFunctiongetMedian
( ar1, ar2 , n)
DSA 450/Arrays/34. Median of two arrays.py:1
↓ 1 callersMethodgetMin
returns min element from stack*/
All Data Structures/Stack/Get_minimum_element_from_stack.cpp:29
↓ 1 callersMethodgetMinDiff
All Data Structures/Arrays/9)Minimize the heights.cpp:7
↓ 1 callersFunctiongetMinMax
All Data Structures/Arrays/2) Maximum and Minimum Element in an Array.cpp:10
↓ 1 callersFunctiongetMoreAndLess
* Given a sorted array Arr of size N and a value X, find the number of array elements less than or equal to X and elements more than or equal to X. */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Smaller_and_Larger.cpp:22
↓ 1 callersFunctiongetNextGap
To find gap between elements
All Algorithms/Sorting Algorithm/comb_sort.cpp:6
↓ 1 callersMethodgetNode
All Data Structures/Singly_LL/main.cpp:57
↓ 1 callersFunctiongetSumUtil
A recursive function to get the sum of values in given range of the array. The following are parameters for this function. si --> Index of current
All Data Structures/Segment Tree/Lazy_Propagation.cpp:105
↓ 1 callersFunctiongetVerticalOrder
DSA 450/Binary Trees/Vertical order traversal.cpp:23
↓ 1 callersFunctiongetZarr
Fills Z array for given string str[]
All Algorithms/String algorithms/Z-algorithm.cpp:31
↓ 1 callersMethodgetdata
Coding Platforms(codechef,codeforces,etc)/HackerRank/Virtual_Functions.cpp:40
↓ 1 callersFunctiongridSearch
Coding Platforms(codechef,codeforces,etc)/HackerRank/Grid_Search/c++/solution.cpp:33
↓ 1 callersMethodgroups
Coding Platforms(codechef,codeforces,etc)/Codeforces/920E.cpp:79
↓ 1 callersFunctionhcf
Basic Programming/HCFofTwoNum.cpp:4
↓ 1 callersFunctionhcf
Coding Platforms(codechef,codeforces,etc)/CodeChef/Practice/Cutting recipie.cpp:5
↓ 1 callersFunctionheapSort
main function to do heap sort
All Data Structures/Sorting/Heap_Sort.cpp:26
↓ 1 callersFunctionheapSort
(arr)
All Algorithms/Sorting Algorithm in Python/heap_Sort.py:28
↓ 1 callersFunctionheap_sort
Heap Sort Function
All Algorithms/Sorting Algorithm/heap_sort.cpp:31
↓ 1 callersFunctionheight_bst
DSA 450/Binary Search Tree/Bst-implementaion.cpp:51
↓ 1 callersFunctionhighestPowerof2
All Algorithms/strassen.cpp:243
↓ 1 callersMethodiSearch
All Data Structures/TREE/BST.cpp:95
↓ 1 callersMethodinOrder
(Node root)
All Data Structures/TREE/TreeImplementationLinkedList.java:34
↓ 1 callersFunctionincrementVetor
(a)
Coding Platforms(codechef,codeforces,etc)/LeetCode/plus_one_pb.py:3
↓ 1 callersFunctioninitStack
initialize stack
All Data Structures/Stack/Sort_stack_using_recursion.cpp:11
↓ 1 callersMethodinorder
()
All Data Structures/Binary Search Tree/BinarySearchTree.java:54
↓ 1 callersMethodinorder
All Data Structures/TREE/AVL.cpp:119
↓ 1 callersMethodinorderRec
(Node root)
All Data Structures/Binary Search Tree/BinarySearchTree.java:58
↓ 1 callersFunctioninorderbst
All Data Structures/Binary Search Tree/One_way_right_threaded_BST.c:130
↓ 1 callersFunctioninsert
All Data Structures/CircularLinkedList/circular_doubly_linked_list.c:54
↓ 1 callersFunctioninsert
All Data Structures/Doubly_LL/palindrome.cpp:18
↓ 1 callersMethodinsert
Insertion
All Data Structures/Trie/trie.h:29
↓ 1 callersFunctioninsertAtBeg
All Data Structures/CircularLinkedList/circular_singly_linked_list.c:40
↓ 1 callersFunctioninsertAtLast
All Data Structures/Stack/reverseStack.cpp:4
↓ 1 callersFunctioninsertAtPosition
All Data Structures/CircularLinkedList/circular_singly_linked_list.c:62
↓ 1 callersMethodinsertBeg
All Data Structures/Doubly_LL/doubly.cpp:27
↓ 1 callersMethodinsertEnd
All Data Structures/Doubly_LL/doubly.cpp:38
↓ 1 callersFunctioninsertNodeAtHead
Coding Platforms(codechef,codeforces,etc)/HackerRank/insert_node_at_head.cpp:57
↓ 1 callersFunctioninsertNodeAtTail
Coding Platforms(codechef,codeforces,etc)/HackerRank/insert_node_at_tail.cpp:57
↓ 1 callersMethodinsertRec
(Node root, int key)
All Data Structures/Binary Search Tree/BinarySearchTree.java:33
↓ 1 callersFunctioninsert_After_Specific
All Data Structures/Singly_LL/menu_based_singly_linked_list.cpp:223
↓ 1 callersFunctioninsert_Before_Specific
All Data Structures/Singly_LL/menu_based_singly_linked_list.cpp:187
↓ 1 callersFunctioninsert_In_Sorted_List
All Data Structures/Singly_LL/menu_based_singly_linked_list.cpp:498
↓ 1 callersFunctioninsert_at_bottom
Below is a recursive function that inserts an element at the bottom of a stack.
DSA 450/Stack/Reverse_stack_using_recursion.cpp:17
↓ 1 callersFunctioninsert_end
All Data Structures/Singly_LL/menu_based_singly_linked_list.cpp:168
↓ 1 callersMethodinsert_node
Coding Platforms(codechef,codeforces,etc)/HackerRank/delete_a_node.cpp:30
↓ 1 callersFunctioninsertelement
All Data Structures/Binary Search Tree/One_way_right_threaded_BST.c:64
↓ 1 callersFunctioninsertionSort
All Data Structures/Sorting/Insertion_sort.cpp:14
↓ 1 callersFunctioninsertionSort
Function to sort an array using insertion sort
All Algorithms/insertion_sort.cpp:7
↓ 1 callersFunctioninsertionSort
In Tim Sort First Run insertion sort and the merge these insertion sort together
All Algorithms/Sorting Algorithm/tim_sort.cpp:8
↓ 1 callersFunctioninsertionSort
All Algorithms/Sorting Algorithm/INSERTION SORT.cpp:4
↓ 1 callersFunctioninsertionSort
(b)
All Algorithms/Sorting Algorithm in Python/bucket_Sort.py:2
↓ 1 callersFunctioninsertionSortRecursive
(array,n)
All Algorithms/Sorting Algorithm in Python/Recursive_Algorithms/insertion_sort.py:1
↓ 1 callersFunctioninsertion_sort
(arr, left=0, right=None)
All Algorithms/Sorting Algorithm in Python/tim_sort.py:1
↓ 1 callersFunctioninsertion_sort
(InputList)
All Algorithms/Sorting Algorithm in Python/insertion.py:6
↓ 1 callersFunctioninsertnode
insert in bst
DSA 450/Binary Search Tree/Bst-implementaion.cpp:199
↓ 1 callersFunctionintsolve
All Data Structures/Arrays/union and intersection of unsorted array.cpp:25
↓ 1 callersFunctioninversePermutation
* Given an array A of size n of integers in the range from 1 to n, we need to find the inverse permutation of that array. */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Inverse_permutation.cpp:22
↓ 1 callersFunctionisAnagram
* Given two strings a and b consisting of lowercase characters. The task is to check whether two given strings are an anagram of each other or not. An
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Anagram.cpp:22
↓ 1 callersFunctionisBalanced
Complete the isBalanced function below.
DSA 450/Stack/Balanced Brackets.cpp:8
↓ 1 callersFunctionisBinary
* Given a non-empty sequence of characters str, return true if sequence is Binary, else return false */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Check_Binary.cpp:22
↓ 1 callersMethodisCycle
(GraphL g)
All Algorithms/Graph Algorithm/KahnsAlgorithmsCycleDetection.java:8
↓ 1 callersMethodisCyclic
All Data Structures/GRAPHS/Detect_Cycle_in_Directed_Graph.cpp:36
↓ 1 callersFunctionisDigitSumPalindrome
* Given a number N.Find if the digit sum(or sum of digits) of N is a Palindrome number or not. */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Sum_of_Digit_of_Palindrome.cpp:22
↓ 1 callersFunctionisFull
Queue is full when size becomes equal to the capacity
Basic Programming/queue.c:32
↓ 1 callersFunctionisPalindrome
* Check if a given number is a palindrome or not. */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Palindrome_check.cpp:22
↓ 1 callersFunctionisPalindrome
* Given a Integer array A[] of n elements. Your task is to complete the function. Which will return 1 if all the elements of the Array are palindrome
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Palindromic_Array.cpp:22
↓ 1 callersFunctionisPatternMatch
Coding Platforms(codechef,codeforces,etc)/HackerRank/Grid_Search/c++/solution.cpp:18
↓ 1 callersFunctionisPowerofTwo
Coding Platforms(codechef,codeforces,etc)/Codeforces/D_1560.cpp:11
↓ 1 callersFunctionisPowerofTwo
Coding Platforms(codechef,codeforces,etc)/Codeforces/A_1688.cpp:10
↓ 1 callersFunctionisShuffledSubstring
DSA 450/String/Check if string is shuffled substring of another string.cpp:4
↓ 1 callersFunctionisSubset
* Given two arrays: a1[0..n-1] of size n and a2[0..m-1] of size m. Task is to check whether a2[] is a subset of a1[] or not. Both the arrays can be so
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Array_subset.cpp:22
↓ 1 callersFunctionisValid
All Data Structures/Stack/valid_parenthesis.cpp:3
↓ 1 callersFunctionisVowel
* Given a English alphabet c, Write a program to check whether a character is a vowel or not. */
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Vowel_or_Not.cpp:22
↓ 1 callersFunctionislandCount
All Data Structures/GRAPHS/island_count.cpp:30
↓ 1 callersFunctionknapSack
All Algorithms/01_0-1_kanpshak.cpp:6
↓ 1 callersFunctionknapsack
All Algorithms/Dynamic Programming/LIS/Knapsack with repititions.cpp:18
↓ 1 callersFunctionknapsack
DSA 450/Dynamic Programming/01_Knapsack.cpp:9
↓ 1 callersMethodkruskal_algo
(self)
All Algorithms/Graph Algorithm/Kruskal Algorithm in Python.py:27
↓ 1 callersMethodkthSmallest
DSA 450/Arrays/3. Kth smallest element.cpp:7
↓ 1 callersMethodkthSmallest
arr : given array l : starting index of the array i.e 0 r : ending index of the array i.e size-1 k : find kth smallest element and return using this f
Basic Programming/Kth smallest elements.cpp:15
↓ 1 callersFunctionlargest
All Algorithms/Sorting Algorithm/RadixSort.cpp:34
↓ 1 callersMethodleader
Coding Platforms(codechef,codeforces,etc)/Codeforces/920E.cpp:63
↓ 1 callersFunctionleftElement
* Given a array of length N, at each step it is reduced by 1 element. In the first step the maximum element would be removed, while in the second step
Coding Platforms(codechef,codeforces,etc)/GeeksforGeeks/Print_the_left_element.cpp:22
↓ 1 callersMethodleftSmaller
All Data Structures/Stack/Smallest_number_on_left.cpp:15
↓ 1 callersFunctionleftView
Iterative function to print the left view of a given binary tree
Accolite/Left view of a binary tree.cpp:19
↓ 1 callersFunctionleftView
All Data Structures/TREE/Left_view_Of_Binary_Tree.cpp:144
↓ 1 callersFunctionleftView
DSA 450/Binary Trees/Leftviewoftree.cpp:134
↓ 1 callersMethodlevelOrder
Function to return the level order traversal of a tree.
DSA 450/Binary Trees/level_order_traversal.cpp:27
↓ 1 callersFunctionlevelorder
function definition of bst
DSA 450/Binary Search Tree/Bst-implementaion.cpp:27
↓ 1 callersFunctionlinearSearch
All Algorithms/Searching Algorithm/linear_search.cpp:5
↓ 1 callersFunctionlongestCommonSubsequence
Coding Platforms(codechef,codeforces,etc)/LeetCode/LCS.cpp:9
↓ 1 callersFunctionlower
Coding Platforms(codechef,codeforces,etc)/CodeChef/Practice/Minimum Maximum.cpp:5
↓ 1 callersFunctionltrim
Coding Platforms(codechef,codeforces,etc)/HackerRank/SubArrayDiv.Cpp:62
↓ 1 callersFunctionltrim
Coding Platforms(codechef,codeforces,etc)/HackerRank/Grid_Search/c++/solution.cpp:107
↓ 1 callersFunctionmain
DSA 450/Arrays/3. Kth smallest element.cpp:14
↓ 1 callersFunctionmain
DSA 450/Arrays/4. Sort an array of 0s, 1s and 2s.cpp:32
← previousnext →401–500 of 2,161, ranked by callers