Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/TheAlgorithms/C
/ functions
Functions
1,322 in github.com/TheAlgorithms/C
⨍
Functions
1,322
◇
Types & classes
204
↓ 2 callers
Function
createState
* @brief creates and initializes a NFA state * @returns pointer to the newly created NFA state */
misc/mcnaughton_yamada_thompson.c:657
↓ 2 callers
Function
create_dict
simple constructor */
data_structures/dictionary/dict.c:6
↓ 2 callers
Function
delete
* @brief To delete a process from the queue * @param root pointer to the head of the queue * @param id process ID * @returns void */
process_scheduling_algorithms/non_preemptive_priority_scheduling.c:81
↓ 2 callers
Function
delete_number
* delete all memory allocated for large number * \param[in] num pointer to large_num to delete */
math/factorial_large_number.c:37
↓ 2 callers
Function
deletion
//////////////////////////////////////////////////////////////
data_structures/linked_list/singly_link_list_deletion.c:64
↓ 2 callers
Function
destroy
data_structures/dictionary/dict.c:100
↓ 2 callers
Function
destroyNode
* @brief recursively destroys a AST * @param node the root node of the tree to be deleted * @returns void */
misc/mcnaughton_yamada_thompson.c:619
↓ 2 callers
Function
display
sorting/radix_sort_2.c:62
↓ 2 callers
Function
display
sorting/gnome_sort.c:24
↓ 2 callers
Function
display
Displays the array, passed to this method*/
sorting/binary_insertion_sort.c:8
↓ 2 callers
Function
display
sorting/comb_sort.c:25
↓ 2 callers
Function
display
Displays the array, passed to this method*/
sorting/quick_sort.c:5
↓ 2 callers
Function
display
Displays the array, passed to this method
sorting/cycle_sort.c:6
↓ 2 callers
Function
display
Displays the array, passed to this method
sorting/pancake_sort.c:55
↓ 2 callers
Function
display
* Displays the array, passed to this method * @param [in] arr array to display * @param [in] n number of elements in the array */
sorting/bead_sort.c:23
↓ 2 callers
Function
enqueue
Inserts item at start of queue
data_structures/graphs/bfs.c:161
↓ 2 callers
Function
error
* @brief Utility function used to print an error message to `stderr`. * It prints `str` and an implementation-defined error * message corresponding
client_server/remote_command_exec_udp_server.c:46
↓ 2 callers
Function
error
* @brief Utility function used to print an error message to `stderr`. * It prints `str` and an implementation-defined error * message corresponding
client_server/tcp_full_duplex_server.c:52
↓ 2 callers
Function
error
* @brief Utility function used to print an error message to `stderr`. * It prints `str` and an implementation-defined error * message corresponding
client_server/tcp_half_duplex_server.c:45
↓ 2 callers
Function
evaluate
* @brief Function to evaluate postfix expression * @param post the input postfix expression * @returns evaluated answer */
misc/postfix_evaluation.c:60
↓ 2 callers
Function
findTargetPath
leetcode/src/236.c:16
↓ 2 callers
Function
flip
Reverses the array */
sorting/pancake_sort.c:6
↓ 2 callers
Function
freeGraph
data_structures/graphs/graph.c:85
↓ 2 callers
Function
freeList
leetcode/src/236.c:43
↓ 2 callers
Function
get
* @brief access the list by index * @param list pointer to the target list * @param index access location * @returns the value at the specified ind
data_structures/linked_list/circular_doubly_linked_list.c:223
↓ 2 callers
Function
getBig
sorting/random_quick_sort.c:13
↓ 2 callers
Function
getCopyCArray
data_structures/array/carray.c:170
↓ 2 callers
Function
getHundred
leetcode/src/12.c:79
↓ 2 callers
Function
getPrecedence
* @brief Helper function that returns each operator's precedence * @param operator the operator to be queried * @returns the operator's precedence
misc/shunting_yard.c:22
↓ 2 callers
Function
getSmall
sorting/random_quick_sort.c:23
↓ 2 callers
Function
getSum
leetcode/src/1283.c:3
↓ 2 callers
Function
get_element_label
data_structures/dictionary/dict.c:77
↓ 2 callers
Function
get_hash
utility function sdbm hash algorithm returns a hashcode for the given string 's' */
data_structures/dictionary/dict.c:33
↓ 2 callers
Function
get_letters
leetcode/src/17.c:15
↓ 2 callers
Function
get_next_abundant
* Find the next abundant number after N and not including N */
project_euler/problem_23/sol2.c:70
↓ 2 callers
Function
get_next_abundant
* Find the next abundant number after N and not including N */
project_euler/problem_23/sol1.c:55
↓ 2 callers
Function
get_number
Function to read the number from a file and store it in array. \n index 0 of output buffer => units place \n index 1 of output buffer => tens
project_euler/problem_13/sol1.c:16
↓ 2 callers
Function
get_rand
* @brief Generate a random number in the given limits * * @param lim1 lower limit * @param lim2 upper limit * @return random number in the given r
math/cartesian_to_polar.c:88
↓ 2 callers
Function
glutBitmapString
A wrapper that is not available in all GLUT implementations. */
graphics/spirograph.c:124
↓ 2 callers
Function
hamming_distance
* @brief Function to calculate the Hamming distance between two strings * @param param1 string 1 * @param param2 string 2 * @returns Hamming distan
misc/hamming_distance.c:21
↓ 2 callers
Function
height
leetcode/src/110.c:3
↓ 2 callers
Function
indexOf
* @brief utility function to locate the first occurrence * of a character in a string while respecting parentheses * @param str target string
misc/mcnaughton_yamada_thompson.c:151
↓ 2 callers
Function
insertionSortCArray
data_structures/array/carray.c:220
↓ 2 callers
Function
intersectionSize
leetcode/src/223.c:3
↓ 2 callers
Function
isArmstrong
Function to check whether the given number is Armstrong number or not
math/armstrong_number.c:30
↓ 2 callers
Function
isEmpty
* @brief Function to check whether the stack is empty or not * @returns 1 if the stack IS empty * @returns 0 if the stack is NOT empty */
conversions/infix_to_postfix2.c:61
↓ 2 callers
Function
isEmpty
* @brief isEmpty function * @param s : it is the object reference of stack * @returns 1 or 0 on exit */
conversions/infix_to_postfix.c:112
↓ 2 callers
Function
isEmpty
Checks for empty queue
data_structures/graphs/bfs.c:153
↓ 2 callers
Function
isPrime
* Check if a given number is prime number or not * @param x number to check * @return `true` if given number is prime number, otherwise `false` */
math/prime.c:16
↓ 2 callers
Function
isStrong
* Check if given number is strong number or not * @param number * @return `true` if given number is strong number, otherwise `false` */
math/strong_number.c:15
↓ 2 callers
Function
is_abundant
* Is the given number an abundant number (1) or not (0) */
project_euler/problem_23/sol2.c:59
↓ 2 callers
Function
is_abundant
* Is the given number an abundant number (1) or not (0) */
project_euler/problem_23/sol1.c:47
↓ 2 callers
Function
is_in
* Check if a number is present in given array * \param[in] N number to check * \param[in] D array to check * \param[in] L length of array * \retur
project_euler/problem_401/sol1.c:28
↓ 2 callers
Function
is_number
* @brief Checks if a character is a number * @param c character to be checked if it's a number or not * @return `true`(1) if the character is a numb
developer_tools/min_printf.h:62
↓ 2 callers
Function
kMeans
! * --K Means Algorithm-- * 1. Assign each observation to one of k groups * creating a random initial clustering * 2. Find the centroid of o
machine_learning/k_means_clustering.c:134
↓ 2 callers
Function
longestDecompositionDpCached
leetcode/src/1147.c:13
↓ 2 callers
Function
max_heapify
sorting/heap_sort.c:7
↓ 2 callers
Function
maxcmp
leetcode/src/53.c:2
↓ 2 callers
Function
maxcmp
leetcode/src/121.c:1
↓ 2 callers
Function
maximizeTarget
leetcode/src/2024.c:3
↓ 2 callers
Function
minimum
* @brief Finds index of minimum element in edge list for an arbitrary vertex * @param arr graph row * @param N number of elements in arr * @returns
greedy_approach/prim.c:45
↓ 2 callers
Function
numberOfWaysForChar
leetcode/src/2222.c:1
↓ 2 callers
Function
oddEvenSort
* @brief oddEvenSort sorts the array using the algorithm described above. * @details * A boolean varaible(isSorted) is declared and initialised to
sorting/odd_even_sort.c:52
↓ 2 callers
Function
pop
data_structures/heap/min_heap.c:119
↓ 2 callers
Function
pop
data_structures/heap/max_heap.c:120
↓ 2 callers
Function
pop
* @brief The pop function to pop an element from the stack. * * @param ptr Stack pointer * @return int Popped value */
data_structures/stack/dynamic_stack.c:124
↓ 2 callers
Function
prim
* @brief Used to find MST of user-generated adj matrix G * @returns void */
greedy_approach/prim.c:65
↓ 2 callers
Function
print
* This function prints the entire Vector as a list. * @params Vector* (a pointer to the Vector struct) * @returns: none */
data_structures/vector.c:125
↓ 2 callers
Function
print
* @brief Print list function * @param list a doubly linked List * @returns void */
data_structures/linked_list/doubly_linked_list.c:256
↓ 2 callers
Function
print
Print sets in the current range to `stdout` * @param head pointer to first set in the current level */
math/cantor_set.c:55
↓ 2 callers
Function
printArray
* @brief Helper function to print an array * @param array pointer to the array * @param length length of the target array * @returns void */
sorting/patience_sort.c:104
↓ 2 callers
Function
printArray
sorting/partition_sort.c:48
↓ 2 callers
Function
printBuckets
sorting/bucket_sort.c:174
↓ 2 callers
Function
printEPS
! * A function to print observations and clusters * The code is taken from * http://rosettacode.org/wiki/K-means%2B%2B_clustering. * Even the K Me
machine_learning/k_means_clustering.c:237
↓ 2 callers
Function
print_number
Function to print a long number */
project_euler/problem_13/sol1.c:92
↓ 2 callers
Function
priority
* @brief Function to check priority of operators * @param opr operator whose priority is to be checked * @returns 0 if operator is '+' or '-' * @re
conversions/infix_to_postfix2.c:83
↓ 2 callers
Function
problem
* @brief Problem statement for a system with first-order differential * equations. Updates the system differential variables. * \note This function
numerical_methods/ode_midpoint_euler.c:54
↓ 2 callers
Function
problem
* @brief Problem statement for a system with first-order differential * equations. Updates the system differential variables. * \note This function
numerical_methods/ode_semi_implicit_euler.c:58
↓ 2 callers
Function
push
* @brief Function to push on the stack * @param opd number to be pushed in the stack * @returns void */
misc/postfix_evaluation.c:31
↓ 2 callers
Function
push
* @brief Function to push on the stack * @param opd character to be pushed in the stack * @returns void */
conversions/infix_to_postfix2.c:32
↓ 2 callers
Function
push
* @brief push function * @param *p : used as a pointer variable of stack * @param x : char to be pushed in stack * @returns void */
conversions/infix_to_postfix.c:55
↓ 2 callers
Function
push
* This function pushes a value to the end of the Vector. * @params Vector* (a pointer to the Vector struct) * @params int (the value to be pushe
data_structures/vector.c:66
↓ 2 callers
Function
put
data_structures/dynamic_array/dynamic_array.c:31
↓ 2 callers
Function
qr_decompose
* Decompose matrix \f$A\f$ using [Gram-Schmidt *process](https://en.wikipedia.org/wiki/QR_decomposition). * * \f{eqnarray*}{ * \text{given that}\q
numerical_methods/qr_decompose.h:142
↓ 2 callers
Function
removeValueCArray
data_structures/array/carray.c:64
↓ 2 callers
Function
retrive_copy_of_value
data_structures/dynamic_array/dynamic_array.c:75
↓ 2 callers
Function
reverseCArray
data_structures/array/carray.c:136
↓ 2 callers
Function
search
* @brief Search value into the list function * @param list a doubly linked list * @param value a value to be looked for into the list *
data_structures/linked_list/doubly_linked_list.c:242
↓ 2 callers
Function
segment_tree_update
* For point updates * This function updates the element at given index and also updates segment * tree accordingly * * @param tree pointer to segm
data_structures/binary_trees/segment_tree.c:79
↓ 2 callers
Function
shoot
* @brief Function shoot * Responsible for saying if he hit a boat * @param mat board * @param line matrix row * @param column matrix column */
games/naval_battle.c:411
↓ 2 callers
Function
show
data_structures/linked_list/ascending_priority_queue.c:119
↓ 2 callers
Function
show
data_structures/linked_list/queue_linked_list.c:80
↓ 2 callers
Function
show_data
sorting/shell_sort.c:13
↓ 2 callers
Function
show_data
* @addtogroup sorting Sorting algorithms * @{ */ Helper function to print array values */
sorting/shell_sort2.c:16
↓ 2 callers
Function
shuntingYard
* @brief An implementation of the shunting yard that converts infix notation to reversed polish notation * @param input pointer to input string * @p
misc/shunting_yard.c:73
↓ 2 callers
Function
solve
* @brief Function to solve a partially filled sudoku matrix. For each unknown * value (0), the function fills a possible value and calls the function
misc/sudoku_solver.c:172
↓ 2 callers
Function
spirograph
Generate spirograph curve into arrays `x` and `y` such that the i^th point * in 2D is represented by `(x[i],y[i])`. The generating function is given
graphics/spirograph.c:57
↓ 2 callers
Function
stats_computer1
* continuous mean and variance computance using * first value as an approximation for the mean. * If the first number is much far form the mean, the
numerical_methods/realtime_stats.c:24
↓ 2 callers
Function
stats_computer2
* continuous mean and variance computance using * Welford's algorithm (very accurate) * \param[in] x new value added to data set * \param[out] mea
numerical_methods/realtime_stats.c:61
↓ 2 callers
Function
sum_of_divisors
* function to return the sum of proper divisors of N */
project_euler/problem_21/sol1.c:13
← previous
next →
201–300 of 1,322, ranked by callers