Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/bighuang624/Algorithms-notes
/ functions
Functions
794 in github.com/bighuang624/Algorithms-notes
⨍
Functions
794
◇
Types & classes
151
Method
point
Draws a point at (x, y). @param x the x-coordinate of the point @param y the y-coordinate of the point
code/algs4/Draw.java:584
Method
poisson
Returns a random integer from a Poisson distribution with mean λ. @param lambda the mean of the Poisson distribution @return a random integer
code/algs4/StdRandom.java:252
Method
polygon
Draws a polygon with the vertices (<em>x</em><sub>0</sub>, <em>y</em><sub>0</sub>), (<em>x</em><sub>1</sub>, <em>y</em><sub>1</sub>), ..., (<em>x</em>
code/algs4/StdDraw.java:1191
Method
polygon
Draws a polygon with the given (x[i], y[i]) coordinates. @param x an array of all the x-coordindates of the polygon @param y an array of all the y-co
code/algs4/Draw.java:786
Method
pop
()
code/chapter1_3_Bags_Queues_Stacks/ResizingArrayStack.java:26
Method
post
()
code/chapter4_2_Directed_Graphs/DepthFirstOrder.java:38
Method
pre
()
code/chapter4_2_Directed_Graphs/DepthFirstOrder.java:34
Method
put
(int i, double x)
code/chapter3_5_Searching_Applications/SparseVector.java:17
Method
put
(Key key, Value val)
code/chapter3_4_Hash_Tables/SeparateChainingHashST.java:34
Method
put
(Key key, Value val)
code/chapter3_1_Symbol_Tables/BinarySearchST.java:60
Method
put
(Key key, Value val)
code/chapter3_1_Symbol_Tables/SequentialSearchST.java:24
Method
r
Returns the polar radius of this point. @return the polar radius of this point in polar coordiantes: sqrt(x x + y y)
code/algs4/Point2D.java:91
Method
radix
Returns the number of characters in this alphabet (the radix). @return the number of characters in this alphabet
code/algs4/Alphabet.java:163
Method
rank
Returns the index of the specified key in the specified array. This function is poorly named because it does not give the <em>rank</em> if the array h
code/algs4/BinarySearch.java:79
Method
rank
(Key key)
code/chapter3_2_Binary_Search_Trees/BST.java:129
Method
reachable
(int v, int w)
code/chapter4_2_Directed_Graphs/TransitiveClosure.java:14
Method
readAllLines
Reads all remaining lines from standard input and returns them as an array of strings. @return all remaining lines on standard input, as an array of s
code/algs4/StdIn.java:431
Method
readAllLines
Reads all remaining lines from this input stream and returns them as an array of strings. @return all remaining lines in this input stream, as an arr
code/algs4/In.java:424
Method
readAllLongs
Reads all remaining tokens from standard input, parses them as longs, and returns them as an array of longs. @return all remaining longs on standard i
code/algs4/StdIn.java:459
Method
readAllLongs
Reads all remaining tokens from this input stream, parses them as longs, and returns them as an array of longs. @return all remaining lines in this i
code/algs4/In.java:453
Method
readBoolean
Reads the next token from this input stream, parses it as a {@code boolean} (interpreting either {@code "true"} or {@code "1"} as {@code true}, and ei
code/algs4/In.java:391
Method
readByte
Reads the next 8 bits from standard input and return as an 8-bit byte. @return the next 8 bits of data from standard input as a {@code byte} @throws
code/algs4/BinaryStdIn.java:271
Method
readByte
Reads the next token from standard input, parses it as a byte, and returns the byte. @return the next byte on standard input @throws NoSuchElementExc
code/algs4/StdIn.java:385
Method
readByte
Reads the next token from this input stream, parses it as a {@code byte}, and returns the {@code byte}. <p> To read binary data, use {@link BinaryIn}.
code/algs4/In.java:380
Method
readChar
Reads and returns the next character. @return the next character @throws NoSuchElementException if standard input is empty
code/algs4/StdIn.java:286
Method
readDouble
Reads the next 64 bits from standard input and return as a 64-bit double. @return the next 64 bits of data from standard input as a {@code double} @t
code/algs4/BinaryStdIn.java:250
Method
readDoubles
Reads all remaining tokens, parses them as doubles, and returns them as an array of doubles. @return all remaining doubles, as an array @throws InputM
code/algs4/StdIn.java:520
Method
readDoubles
Reads all doubles from a file and returns them as an array of doubles. @param filename the name of the file @return the doubles in the file
code/algs4/In.java:505
Method
readFloat
Reads the next 32 bits from standard input and return as a 32-bit float. @return the next 32 bits of data from standard input as a {@code float} @thr
code/algs4/BinaryStdIn.java:260
Method
readFloat
Reads the next token from standard input, parses it as a float, and returns the float. @return the next float on standard input @throws NoSuchElement
code/algs4/StdIn.java:352
Method
readFloat
Reads the next token from this input stream, parses it as a {@code float}, and returns the {@code float}. @return the next {@code float} in this inpu
code/algs4/In.java:348
Method
readInts
Reads all remaining tokens, parses them as integers, and returns them as an array of integers. @return all remaining integers, as an array @throws Inp
code/algs4/StdIn.java:508
Method
readLong
Reads the next token from standard input, parses it as a long integer, and returns the long integer. @return the next long integer on standard input
code/algs4/StdIn.java:363
Method
readLong
Reads the next token from this input stream, parses it as a {@code long}, and returns the {@code long}. @return the next {@code long} in this input s
code/algs4/In.java:358
Method
readShort
Reads the next 16 bits from standard input and return as a 16-bit short. @return the next 16 bits of data from standard input as a {@code short} @thr
code/algs4/BinaryStdIn.java:178
Method
readShort
Reads the next token from standard input, parses it as a short integer, and returns the short integer. @return the next short integer on standard inp
code/algs4/StdIn.java:374
Method
readShort
Reads the next token from this input stream, parses it as a {@code short}, and returns the {@code short}. @return the next {@code short} in this inpu
code/algs4/In.java:368
Method
readString
Reads the remaining bytes of data from standard input and return as a string. @return the remaining bytes of data from standard input as a {@code Str
code/algs4/BinaryStdIn.java:160
Method
readStrings
Reads all remaining tokens and returns them as an array of strings. @return all remaining tokens, as an array of strings @deprecated Replaced by {@lin
code/algs4/StdIn.java:530
Method
readStrings
Reads all strings from a file and returns them as an array of strings. @param filename the name of the file @return the strings in the file
code/algs4/In.java:518
Method
rectangle
Draws a rectangle of given half width and half height, centered on (x, y). @param x the x-coordinate of the center of the rectangle @param y the y-
code/algs4/Draw.java:747
Method
remove
()
code/algs4/Stack.java:160
Method
remove
()
code/algs4/IndexMinPQ.java:320
Method
remove
()
code/algs4/Queue.java:152
Method
remove
()
code/algs4/MinPQ.java:261
Method
remove
()
code/chapter1_3_Bags_Queues_Stacks/ResizingArrayStack.java:46
Method
right
Returns the right endpoint of this interval. @return the right endpoint of this interval @deprecated Replaced by {@link #max()}.
code/algs4/Interval1D.java:93
Method
select
(int k)
code/chapter3_1_Symbol_Tables/BinarySearchST.java:86
Method
select
(int k)
code/chapter3_2_Binary_Search_Trees/BST.java:112
Method
setLocationOnScreen
Sets the upper-left hand corner of the drawing window to be (x, y), where (0, 0) is upper left. @param x the number of pixels from the left @param
code/algs4/Draw.java:308
Method
setOriginLowerLeft
Sets the origin to be the lower left pixel.
code/algs4/Picture.java:183
Method
setOriginUpperLeft
Sets the origin to be the upper left pixel. This is the default.
code/algs4/Picture.java:176
Method
setScale
Sets the <em>x</em>-scale and <em>y</em>-scale to be the default (between 0.0 and 1.0).
code/algs4/StdDraw.java:738
Method
show
(Comparable[] a)
code/chapter2_3_Quicksort/Quick3way.java:67
Method
show
(Comparable[] a)
code/chapter2_3_Quicksort/Quick.java:57
Method
show
(Comparable[] a)
code/chapter2_3_Quicksort/Ex25.java:87
Method
show
(Comparable[] a)
code/chapter2_2_Mergesort/MergeBU.java:52
Method
show
(Comparable[] a)
code/chapter2_2_Mergesort/Merge.java:59
Method
show
(Comparable[] a)
code/chapter2_1_Elementary_Sorts/Selection.java:36
Method
show
(Comparable[] a)
code/chapter2_1_Elementary_Sorts/Insertion.java:34
Method
show
(Comparable[] a)
code/chapter2_1_Elementary_Sorts/Shell.java:40
Method
size
()
code/chapter2_4_Priority_Queues/MaxPQ.java:37
Method
size
()
code/chapter3_5_Searching_Applications/SparseVector.java:14
Method
size
()
code/chapter3_4_Hash_Tables/LinearProbingHashST.java:23
Method
size
Returns the number of keys on this priority queue. @return the number of keys on this priority queue
code/algs4/IndexMinPQ.java:97
Method
size
()
code/chapter3_1_Symbol_Tables/BinarySearchST.java:27
Method
sort
(Comparable[] a)
code/chapter2_3_Quicksort/Quick.java:12
Method
sort
(Comparable[] a)
code/chapter2_2_Mergesort/MergeBU.java:13
Method
sort
(Comparable[] a)
code/chapter2_2_Mergesort/Merge.java:13
Method
stronglyConnected
(int v, int w)
code/chapter4_2_Directed_Graphs/KosarajuSCC.java:30
Method
textLeft
Write the given text string in the current font, left-aligned at (<em>x</em>, <em>y</em>). @param x the <em>x</em>-coordinate of the text @param y t
code/algs4/StdDraw.java:1490
Method
textLeft
Writes the given text string in the current font, left-aligned at (x, y). @param x the x-coordinate of the text @param y the y-coordinate of the text
code/algs4/Draw.java:1010
Method
textRight
Write the given text string in the current font, right-aligned at (<em>x</em>, <em>y</em>). @param x the <em>x</em>-coordinate of the text @param y
code/algs4/StdDraw.java:1508
Method
theta
Returns the angle of this point in polar coordinates. @return the angle (in radians) of this point in polar coordiantes (between -pi/2 and pi/2)
code/algs4/Point2D.java:99
Method
timeToHit
Returns the amount of time for this particle to collide with the specified particle, assuming no interening collisions. @param that the other partic
code/algs4/Particle.java:118
Method
timeToHitHorizontalWall
Returns the amount of time for this particle to collide with a horizontal wall, assuming no interening collisions. @return the amount of time for thi
code/algs4/Particle.java:159
Method
timeToHitVerticalWall
Returns the amount of time for this particle to collide with a vertical wall, assuming no interening collisions. @return the amount of time for this
code/algs4/Particle.java:144
Method
toString
Returns a string representation of this stack. @return the sequence of items in this stack in LIFO order, separated by spaces
code/algs4/Stack.java:129
Method
toString
Returns a string representation of this interval. @return a string representation of this interval in the form [min, max]
code/algs4/Interval1D.java:154
Method
toString
Return a string representation of this point. @return a string representation of this point in the format (x, y)
code/algs4/Point2D.java:299
Method
toString
Returns a string representation of this queue. @return the sequence of items in FIFO order, separated by spaces
code/algs4/Queue.java:125
Method
toString
Returns a string representation of this two-dimensional interval. @return a string representation of this two-dimensional interval in the form [xmi
code/algs4/Interval2D.java:77
Method
toString
Returns a string representation of this counter. @return a string representation of this counter
code/algs4/Counter.java:68
Method
toString
()
code/chapter4_3_Minimum_Spanning_Tree/Edge.java:45
Method
toString
()
code/chapter4_4_Shortest_Paths/DirectedEdge.java:30
Method
toString
()
code/chapter1_2_Data_Abstraction/VisualAccumulator.java:26
Method
toString
()
code/chapter1_2_Data_Abstraction/Date.java:22
Method
toString
()
code/chapter1_2_Data_Abstraction/Accumulator.java:13
Method
union
Returns the union of this set and that set. @param that the other set @return the union of this set and that set @throws IllegalArgumentException if
code/algs4/SET.java:198
Method
union
(int p, int q)
code/chapter1_5_Case_Study_Union_Find/WeightedQuickUnionUF.java:37
Method
weight
()
code/chapter4_3_Minimum_Spanning_Tree/KruskalMST.java:30
Method
weight
()
code/chapter4_3_Minimum_Spanning_Tree/LazyPrimMST.java:49
Method
xorOff
Turns off xor mode.
code/algs4/Draw.java:512
Method
xorOn
Turns on xor mode.
code/algs4/Draw.java:505
← previous
701–794 of 794, ranked by callers