MCPcopy Create free account

hub / github.com/code-golf/code-golf / functions

Functions650 in github.com/code-golf/code-golf

↓ 3 callersMethodSaveSettings
SaveSettings saves golfer.Settings back to the DB.
golfer/golfer.go:157
↓ 3 callersMethodScan
(v any)
golfer/golfer.go:178
↓ 3 callersFunctionasNode
(val int)
hole/reverse-polish-notation.go:16
↓ 3 callersFunctionawardCheevos
(db *sqlx.DB, earnedUsers map[int]time.Time, cheevoID string)
github/github.go:69
↓ 3 callersFunctionbanners
(golfer *golfer.Golfer)
routes/banner.go:19
↓ 3 callersFunctioncheckShowAddRow
()
assets/js/hole/tabs.tsx:589
↓ 3 callersFunctioncol
(width: number)
assets/js/_diff.tsx:174
↓ 3 callersFunctionctrlEnter
(func: Function)
assets/js/_hole-common.tsx:871
↓ 3 callersFunctiondefaultMatchPriority
(haystack: string, needle: string)
assets/js/_search-nav.ts:15
↓ 3 callersFunctionexpand
(node *Node)
hole/reverse-polish-notation.go:18
↓ 3 callersFunctionflipReversiBoard
(board ReversiBoard, bottomLeft, bottomRight bool)
hole/reversi.go:106
↓ 3 callersFunctionformatScore
(scoring: any)
assets/js/hole/classic.tsx:26
↓ 3 callersFunctionformatScore
(scoring: any)
assets/js/hole/tabs.tsx:160
↓ 3 callersFunctiongcd
(a, b int)
hole/0hole.go:155
↓ 3 callersMethodget4
(i, j, dir int)
hole/qr.go:32
↓ 3 callersFunctiongetCurrentSolutionCode
()
assets/js/_hole-common.tsx:183
↓ 3 callersFunctiongetDiffRow
(hole: string, change1: Diff.Change, change2: Diff.Change, pos: DiffPos, argv: string[], ignoreCase: boolean,
assets/js/_diff.tsx:299
↓ 3 callersFunctiongetReversiInitialState
()
hole/reversi.go:98
↓ 3 callersFunctiongetScoring
(str: string, index: 0 | 1)
assets/js/_hole-common.tsx:172
↓ 3 callersFunctioninRange
(x, y int)
hole/reversi.go:29
↓ 3 callersFunctionisHandValid
(tileCounts map[rune]int)
hole/mahjong.go:166
↓ 3 callersFunctionprintNumbrix
(puzzle [boardSize][boardSize]int)
hole/numbrix.go:230
↓ 3 callersFunctionprocessResults
(results: SearchNavResultInternal[])
assets/js/_search-nav.ts:112
↓ 3 callersFunctionrandomBFCase
(jumpSize, buckets, initialBucketSize, bucketSizeChange, charShift int)
hole/brainfuck.go:34
↓ 3 callersFunctionrandomPrime
(max int)
hole/jacobi-symbol.go:24
↓ 3 callersFunctionredir
(w http.ResponseWriter, r *http.Request, old, new string, code int)
middleware/redir_holes_langs.go:38
↓ 3 callersFunctionreduce
(n, d int)
hole/quadratic-formula.go:14
↓ 3 callersFunctionrenderResults
()
assets/js/base.tsx:125
↓ 3 callersFunctionscanIDs
Very crude pg array parsing, only one-dimensional arrays. See https://github.com/lib/pq/blob/master/array.go for proper parsing.
config/sql.go:47
↓ 3 callersFunctionsetCodeForLangAndSolution
(editor: any)
assets/js/_hole-common.tsx:742
↓ 3 callersFunctionsetState
(code: string, editor: EditorView)
assets/js/_hole-common.tsx:196
↓ 3 callersFunctionsetTall
(b: boolean)
assets/js/hole/tabs.tsx:550
↓ 3 callersFunctionsetWide
(b: boolean)
assets/js/hole/tabs.tsx:545
↓ 3 callersFunctionsolve
(a, b, c int)
hole/quadratic-formula.go:39
↓ 3 callersFunctionupdateReadonlyPanels
(data: ReadonlyPanelsData | {langWiki: string}| {holeLangNotes: string})
assets/js/hole/tabs.tsx:112
↓ 3 callersFunctionupdateRestoreLinkVisibility
(editor: any)
assets/js/_hole-common.tsx:729
↓ 2 callersMethodFresh
Fresh lang is one that was released in the last 1,000 hours (~42 days).
config/langs.go:55
↓ 2 callersFunctionHTML2Text
HTML2Text converts HTML into plain text. All whitespace collapses to space.
pretty/pretty.go:52
↓ 2 callersFunctionList
()
zone/zone.go:81
↓ 2 callersFunctionOrdinal
Ordinal returns the ordinal of an integer.
pretty/pretty.go:90
↓ 2 callersFunctionParse
(s string)
uuid/uuid.go:13
↓ 2 callersFunctionPlay
Play a given hole, in a given lang, with given code and return the runs.
hole/play.go:66
↓ 2 callersMethodPrepareNamed
(string)
db/db.go:42
↓ 2 callersMethodPush
(x any)
hole/huffman.go:46
↓ 2 callersMethodQueryRowContext
(context.Context, string, ...any)
db/db.go:47
↓ 2 callersFunctionRouter
(db *sqlx.DB)
routes/routes.go:11
↓ 2 callersFunctionRun
(db *sqlx.DB, hourly bool)
github/github.go:34
↓ 2 callersMethodSelectContext
(context.Context, any, string, ...any)
db/db.go:49
↓ 2 callersMethodString
()
zone/zone.go:76
↓ 2 callersMethodUnmarshalText
(b []byte)
uuid/uuid.go:33
↓ 2 callersMethodValue
()
uuid/uuid.go:58
↓ 2 callersFunctionWalk
(JsonNode node)
langs/f-sharp/trimmer.cs:32
↓ 2 callersFunctionapplyViewState
(viewState: ViewState)
assets/js/hole/tabs.tsx:480
↓ 2 callersFunctionarabicToRoman
(reverse bool)
hole/arabic-to-roman.go:16
↓ 2 callersFunctionasString
(src any)
config/sql.go:30
↓ 2 callersFunctionawardRoles
(db *sqlx.DB, members map[string]any, roleID, sql string)
discord/bot.go:283
↓ 2 callersFunctionbadgeTextWidth
(s string)
routes/badge.go:167
↓ 2 callersFunctionboxGen
generator of random non-null boxes (i.e. with area != 0)
hole/intersection.go:46
↓ 2 callersFunctioncalculateIntersection
(b1, b2 bbox)
hole/intersection.go:24
↓ 2 callersFunctionchannel
(hole *config.Hole, lang *config.Lang)
discord/bot.go:100
↓ 2 callersFunctionchess960
(reverse bool)
hole/chess960.go:12
↓ 2 callersFunctioncontinuedFractionsTest
(n, d int)
hole/continued-fractions.go:28
↓ 2 callersFunctiondeepCancelTouchStart
* Golden Layout has handlers for both "touchstart" and "click," which is a * problem because a touch on mobile triggers both events (example symptom:
assets/js/hole/tabs.tsx:704
↓ 2 callersFunctiondiffWrapper
(join: string, left: string[], right: string[], diffOpts: Diff.BaseOptions)
assets/js/_diff.tsx:89
↓ 2 callersFunctiondraw
(grid [height][width]int, si, sj, ei, ej int, path [height][width]int, drawpath bool)
hole/maze.go:79
↓ 2 callersFunctiondrawRect
(rect [rectSize][rectSize]byte)
hole/rectangle-fill.go:57
↓ 2 callersFunctiondrawReversiBoard
(board ReversiBoard)
hole/reversi.go:160
↓ 2 callersFunctiongenRandomPair
()
hole/mahjong.go:68
↓ 2 callersFunctiongenValidHand
()
hole/mahjong.go:121
↓ 2 callersMethodget2
(i, j int)
hole/qr.go:28
↓ 2 callersFunctiongetClosestMultiset
(anyAnswer, stdout, multisetItemDelimiter string, caseFold bool)
hole/judges.go:96
↓ 2 callersFunctiongetDiffLines
(hole: string, left: Diff.Change, right: Diff.Change, pos: DiffPos, argv: string[], ignoreCase: boolean, isArg
assets/js/_diff.tsx:307
↓ 2 callersFunctiongetDisplayPointsChange
(points: number, delta: number)
assets/js/_hole-common.tsx:408
↓ 2 callersFunctiongetDisplayRank
(rank: number)
assets/js/_hole-common.tsx:402
↓ 2 callersFunctiongetDisplayRankChange
(rank: number, delta: number)
assets/js/_hole-common.tsx:405
↓ 2 callersFunctiongetHomeCards
Get homepage cards with order based on homepage settings.
routes/home_cards.go:54
↓ 2 callersFunctiongetLastSubmittedCode
()
assets/js/_hole-common.tsx:545
↓ 2 callersFunctiongetOtherScoring
(value: 0 | 1)
assets/js/_hole-common.tsx:168
↓ 2 callersFunctiongetPotentialSpots
(team ReversiTile, grid ReversiBoard)
hole/reversi.go:38
↓ 2 callersFunctiongetScorings
(tr: any, editor: any)
assets/js/_hole-common.tsx:835
↓ 2 callersFunctiongetTileNumber
Gets the numerical value of a tile
hole/mahjong.go:9
↓ 2 callersFunctiongrayCode
(reverse bool)
hole/gray-code.go:8
↓ 2 callersFunctiongroupsCheevos
()
config/nav.go:190
↓ 2 callersFunctionhighlightCodeBlocks
(selector: string)
assets/js/_wiki.ts:5
↓ 2 callersFunctioninit
(_tabLayout: boolean, setSolution: any, setCodeForLangAndSolution: any, updateReadonlyPanels: any, getEditor:
assets/js/_hole-common.tsx:58
↓ 2 callersFunctioninitCopyButtons
(buttons: NodeListOf<HTMLElement>)
assets/js/_hole-common.tsx:119
↓ 2 callersFunctioninitDeleteBtn
(deleteBtn: HTMLElement | undefined)
assets/js/_hole-common.tsx:110
↓ 2 callersMethodisIrreducible
If numerator and denominator are divisible by a number greater than 1 then the fraction is reducible.
hole/fractions.go:12
↓ 2 callersFunctionisLeap
(year int)
hole/calendar.go:30
↓ 2 callersFunctionlinesDiff
(hole: string, exp: string, out: string, argv: string[], ignoreCase: boolean)
assets/js/_diff.tsx:49
↓ 2 callersFunctionmakeCode
Create a string containing the given number of characters and UTF-8 encoded bytes.
utils/update_sql_from_api.go:29
↓ 2 callersFunctionmakeSingular
(strokes: number, units: string)
assets/js/_hole-common.tsx:399
↓ 2 callersFunctionmessageEmbedAuthor
(golfer *Golfer.Golfer)
discord/bot.go:463
↓ 2 callersFunctionmorse
(reverse bool)
hole/morse.go:48
↓ 2 callersFunctionmultiTapConvert
(text string)
hole/multitap-input.go:65
↓ 2 callersFunctionnormalize
(str: string)
assets/js/_search-nav.ts:16
↓ 2 callersFunctiononeOfPerOutputJudge
Creates a judge which checks whether each user output corresponds to one of preset outputs corresponding to the respective arg.
hole/judges.go:58
↓ 2 callersFunctionord
(i: number)
assets/js/_util.ts:2
↓ 2 callersFunctionotherTeam
(team ReversiTile)
hole/reversi.go:19
↓ 2 callersFunctionpAdicTest
(p, n, d int)
hole/p-adic-expansion.go:14
← previousnext →101–200 of 650, ranked by callers