ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Log2.lean

full_name: Nat.log2_terminates
code: theorem log2_terminates : ∀ n, n ≥ 2 → n / 2 < n
  
goal: n ≥ 2 → n / 2 < n

full_name: Nat.log2
code: /--
Computes `⌊max 0 (log₂ n)⌋`.

`log2 0 = log2 1 = 0`, `log2 2 = 1`, ..., `log2 (2^i) = i`, etc.
-/
@[extern "lean_nat_log2"]
def log2 (n : @& Nat) : Nat 
goal: Nat

full_name: Nat.log2_le_self
code: theorem log2_le_self (n : Nat) : Nat.log2 n ≤ n 
goal: n.log2 ≤ n
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Control.lean

full_name: Nat.forM.loop
code: @[inline] def forM {m} [Monad m] (n : Nat) (f : Nat → m Unit) : m Unit 
goal: Nat → m Unit

full_name: Nat.forM
code: @[inline] def forM {m} [Monad m] (n : Nat) (f : Nat → m Unit) : m Unit 
goal: m Unit

full_name: Nat.forRevM.loop
code: @[inline] def forRevM {m} [Monad m] (n : Nat) (f : Nat → m Unit) : m Unit 
goal: Nat → m Unit

full_name: Nat.forRevM
code: @[inline] def forRevM {m} [Monad m] (n : Nat) (f : Nat → m Unit) : m Unit 
goal: m Unit

full_name: Nat.foldM.loop
code: @[inline] def foldM {α : Type u} {m : Type u → Type v} [Monad m] (f : Nat → α → m α) (init : α) (n : Nat) : m α 
goal: Nat → α → m α

full_name: Nat.foldM
code: @[inline] def foldM {α : Type u} {m : Type u → Type v} [Monad m] (f : Nat → α → m α) (init : α) (n : Nat) : m α 
goal: m α

full_name: Nat.foldRevM
code: @[inline] def foldRevM {α : Type u} {m : Type u → Type v} [Monad m] (f : Nat → α → m α) (init : α) (n : Nat) : m α 
goal: m α

full_name: Nat.foldRevM.loop
code: @[inline] def foldRevM {α : Type u} {m : Type u → Type v} [Monad m] (f : Nat → α → m α) (init : α) (n : Nat) : m α 
goal: Nat → α → m α

full_name: Nat.allM.loop
code: @[inline] def allM {m} [Monad m] (n : Nat) (p : Nat → m Bool) : m Bool 
goal: Nat → m Bool

full_name: Nat.allM
code: @[inline] def allM {m} [Monad m] (n : Nat) (p : Nat → m Bool) : m Bool 
goal: m Bool

full_name: Nat.anyM.loop
code: @[inline] def anyM {m} [Monad m] (n : Nat) (p : Nat → m Bool) : m Bool 
goal: Nat → m Bool

full_name: Nat.anyM
code: @[inline] def anyM {m} [Monad m] (n : Nat) (p : Nat → m Bool) : m Bool 
goal: m Bool
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Mod.lean

full_name: Nat.mul_lt_mul_left
code: @[simp] protected theorem mul_lt_mul_left (a0 : 0 < a) : a * b < a * c ↔ b < c 
goal: a * b < a * c ↔ b < c

full_name: Nat.mul_lt_mul_right
code: @[simp] protected theorem mul_lt_mul_right (a0 : 0 < a) : b * a < c * a ↔ b < c 
goal: b * a < c * a ↔ b < c

full_name: Nat.lt_of_mul_lt_mul_left
code: protected theorem lt_of_mul_lt_mul_left {a b c : Nat} (h : a * b < a * c) : b < c 
goal: b < c

full_name: Nat.lt_of_mul_lt_mul_right
code: protected theorem lt_of_mul_lt_mul_right {a b c : Nat} (h : b * a < c * a) : b < c 
goal: b < c

full_name: Nat.div_lt_of_lt_mul
code: protected theorem div_lt_of_lt_mul {m n k : Nat} (h : m < n * k) : m / n < k 
goal: m / n < k

full_name: Nat.mod_mul_right_div_self
code: theorem mod_mul_right_div_self (m n k : Nat) : m % (n * k) / n = m / n % k 
goal: m % (n * k) / n = m / n % k

full_name: Nat.mod_mul_left_div_self
code: theorem mod_mul_left_div_self (m n k : Nat) : m % (k * n) / n = m / n % k 
goal: m % (k * n) / n = m / n % k

full_name: Nat.mod_mul_right_mod
code: @[simp 1100]
theorem mod_mul_right_mod (a b c : Nat) : a % (b * c) % b = a % b 
goal: a % (b * c) % b = a % b

full_name: Nat.mod_mul_left_mod
code: @[simp 1100]
theorem mod_mul_left_mod (a b c : Nat) : a % (b * c) % c = a % c 
goal: a % (b * c) % c = a % c

full_name: Nat.mod_mul
code: theorem mod_mul {a b x : Nat} : x % (a * b) = x % a + a * (x / a % b) 
goal: x % (a * b) = x % a + a * (x / a % b)

full_name: Nat.mod_pow_succ
code: theorem mod_pow_succ {x b k : Nat} :
    x % b ^ (k + 1) = x % b ^ k + b ^ k * ((x / b ^ k) % b) 
goal: x % b ^ (k + 1) = x % b ^ k + b ^ k * (x / b ^ k % b)
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Compare.lean

full_name: Nat.compare_def_lt
code: theorem compare_def_lt (a b : Nat) :
    compare a b = if a < b then .lt else if b < a then .gt else .eq 
goal: compare a b = if a < b then Ordering.lt else if b < a then Ordering.gt else Ordering.eq

full_name: Nat.compare_def_le
code: theorem compare_def_le (a b : Nat) :
    compare a b = if a ≤ b then if b ≤ a then .eq else .lt else .gt 
goal: compare a b = if a ≤ b then if b ≤ a then Ordering.eq else Ordering.lt else Ordering.gt

full_name: Nat.compare_swap
code: protected theorem compare_swap (a b : Nat) : (compare a b).swap = compare b a 
goal: (compare a b).swap = compare b a

full_name: Nat.compare_eq_eq
code: protected theorem compare_eq_eq {a b : Nat} : compare a b = .eq ↔ a = b 
goal: compare a b = Ordering.eq ↔ a = b

full_name: Nat.compare_eq_lt
code: protected theorem compare_eq_lt {a b : Nat} : compare a b = .lt ↔ a < b 
goal: compare a b = Ordering.lt ↔ a < b

full_name: Nat.compare_eq_gt
code: protected theorem compare_eq_gt {a b : Nat} : compare a b = .gt ↔ b < a 
goal: compare a b = Ordering.gt ↔ b < a

full_name: Nat.compare_ne_gt
code: protected theorem compare_ne_gt {a b : Nat} : compare a b ≠ .gt ↔ a ≤ b 
goal: compare a b ≠ Ordering.gt ↔ a ≤ b

full_name: Nat.compare_ne_lt
code: protected theorem compare_ne_lt {a b : Nat} : compare a b ≠ .lt ↔ b ≤ a 
goal: compare a b ≠ Ordering.lt ↔ b ≤ a
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Lcm.lean

full_name: Nat.lcm
code: /-- The least common multiple of `m` and `n`, defined using `gcd`. -/
def lcm (m n : Nat) : Nat 
goal: Nat

full_name: Nat.lcm_comm
code: theorem lcm_comm (m n : Nat) : lcm m n = lcm n m 
goal: m.lcm n = n.lcm m

full_name: Nat.instCommutativeLcm
code: instance : Std.Commutative lcm 
goal: Std.Commutative Nat.lcm

full_name: Nat.lcm_zero_left
code: @[simp] theorem lcm_zero_left (m : Nat) : lcm 0 m = 0 
goal: Nat.lcm 0 m = 0

full_name: Nat.lcm_zero_right
code: @[simp] theorem lcm_zero_right (m : Nat) : lcm m 0 = 0 
goal: m.lcm 0 = 0

full_name: Nat.lcm_one_left
code: @[simp] theorem lcm_one_left (m : Nat) : lcm 1 m = m 
goal: Nat.lcm 1 m = m

full_name: Nat.lcm_one_right
code: @[simp] theorem lcm_one_right (m : Nat) : lcm m 1 = m 
goal: m.lcm 1 = m

full_name: Nat.instLawfulIdentityLcmOfNat
code: instance : Std.LawfulIdentity lcm 1 
goal: Std.LawfulIdentity Nat.lcm 1

full_name: Nat.lcm_self
code: @[simp] theorem lcm_self (m : Nat) : lcm m m = m 
goal: m.lcm m = m

full_name: Nat.instIdempotentOpLcm
code: instance : Std.IdempotentOp lcm 
goal: Std.IdempotentOp Nat.lcm

full_name: Nat.dvd_lcm_left
code: theorem dvd_lcm_left (m n : Nat) : m ∣ lcm m n 
goal: m ∣ m.lcm n

full_name: Nat.dvd_lcm_right
code: theorem dvd_lcm_right (m n : Nat) : n ∣ lcm m n 
goal: n ∣ m.lcm n

full_name: Nat.gcd_mul_lcm
code: theorem gcd_mul_lcm (m n : Nat) : gcd m n * lcm m n = m * n 
goal: m.gcd n * m.lcm n = m * n

full_name: Nat.lcm_dvd
code: theorem lcm_dvd {m n k : Nat} (H1 : m ∣ k) (H2 : n ∣ k) : lcm m n ∣ k 
goal: m.lcm n ∣ k

full_name: Nat.lcm_assoc
code: theorem lcm_assoc (m n k : Nat) : lcm (lcm m n) k = lcm m (lcm n k) 
goal: (m.lcm n).lcm k = m.lcm (n.lcm k)

full_name: Nat.instAssociativeLcm
code: instance : Std.Associative lcm 
goal: Std.Associative Nat.lcm

full_name: Nat.lcm_ne_zero
code: theorem lcm_ne_zero (hm : m ≠ 0) (hn : n ≠ 0) : lcm m n ≠ 0 
goal: m.lcm n ≠ 0
File: .lake/packages/lean4/src/lean/Init/Data/OfScientific.lean

full_name: OfScientific.ofScientific
code: /-- For decimal and scientific numbers (e.g., `1.23`, `3.12e10`).
   Examples:
   - `OfScientific.ofScientific 123 true 2`    represents `1.23`
   - `OfScientific.ofScientific 121 false 100` represents `121e100`
-/
class OfScientific (α : Type u) where
  ofScientific (mantissa : Nat) (exponentSign : Bool) (decimalExponent : Nat) : α
goal: α

full_name: OfScientific
code: /-- For decimal and scientific numbers (e.g., `1.23`, `3.12e10`).
   Examples:
   - `OfScientific.ofScientific 123 true 2`    represents `1.23`
   - `OfScientific.ofScientific 121 false 100` represents `121e100`
-/
class OfScientific (α : Type u) where
  ofScientific (mantissa : Nat) (exponentSign : Bool) (decimalExponent : Nat) : α
goal: Type u

full_name: Float.ofBinaryScientific
code: /-- Computes `m * 2^e`. -/
def Float.ofBinaryScientific (m : Nat) (e : Int) : Float 
goal: Float

full_name: Float.ofScientific
code: protected opaque Float.ofScientific (m : Nat) (s : Bool) (e : Nat) : Float 
goal: Float

full_name: instOfScientificFloat
code: /--
  The `OfScientific Float` must have priority higher than `mid` since
  the default instance `Neg Int` has `mid` priority.
  ```
  #check -42.0 -- must be Float
  ```
-/
@[default_instance mid+1]
instance : OfScientific Float 
goal: OfScientific Float

full_name: Float.ofNat
code: @[export lean_float_of_nat]
def Float.ofNat (n : Nat) : Float 
goal: Float

full_name: Float.ofInt
code: def Float.ofInt : Int → Float
  
goal: Int → Float

full_name: «instOfNatFloat_.lake»
code: instance : OfNat Float n   
goal: OfNat Float n

full_name: Nat.toFloat
code: abbrev Nat.toFloat (n : Nat) : Float 
goal: Float
File: .lake/packages/lean4/src/lean/Init/Data/Nat/Power2.lean

full_name: Nat.two_pow_pos
code: protected theorem two_pow_pos (w : Nat) : 0 < 2^w 
goal: 0 < 2 ^ w

full_name: Nat.nextPowerOfTwo_dec
code: theorem nextPowerOfTwo_dec {n power : Nat} (h₁ : power > 0) (h₂ : power < n) : n - power * 2 < n - power 
goal: n - power * 2 < n - power

full_name: Nat.nextPowerOfTwo.go
code: def nextPowerOfTwo (n : Nat) : Nat 
goal: Nat

full_name: Nat.nextPowerOfTwo
code: def nextPowerOfTwo (n : Nat) : Nat 
goal: Nat

full_name: Nat.isPowerOfTwo
code: def isPowerOfTwo (n : Nat) 
goal: Prop

full_name: Nat.one_isPowerOfTwo
code: theorem one_isPowerOfTwo : isPowerOfTwo 1 
goal: Nat.isPowerOfTwo 1

full_name: Nat.mul2_isPowerOfTwo_of_isPowerOfTwo
code: theorem mul2_isPowerOfTwo_of_isPowerOfTwo (h : isPowerOfTwo n) : isPowerOfTwo (n * 2) 
goal: (n * 2).isPowerOfTwo

full_name: Nat.pos_of_isPowerOfTwo
code: theorem pos_of_isPowerOfTwo (h : isPowerOfTwo n) : n > 0 
goal: n > 0

full_name: Nat.isPowerOfTwo_nextPowerOfTwo.isPowerOfTwo_go
code: theorem isPowerOfTwo_nextPowerOfTwo (n : Nat) : n.nextPowerOfTwo.isPowerOfTwo 
goal: (Nat.nextPowerOfTwo.go n power h₁).isPowerOfTwo

full_name: Nat.isPowerOfTwo_nextPowerOfTwo
code: theorem isPowerOfTwo_nextPowerOfTwo (n : Nat) : n.nextPowerOfTwo.isPowerOfTwo 
goal: n.nextPowerOfTwo.isPowerOfTwo
File: .lake/packages/lean4/src/lean/Init/Data/Array/DecidableEq.lean

full_name: Array.eq_of_isEqvAux
code: theorem eq_of_isEqvAux [DecidableEq α] (a b : Array α) (hsz : a.size = b.size) (i : Nat) (hi : i ≤ a.size) (heqv : Array.isEqvAux a b hsz (fun x y => x = y) i) (j : Nat) (low : i ≤ j) (high : j < a.size) : a[j] = b[j]'(hsz ▸ high) 
goal: a[j] = b[j]

full_name: Array.eq_of_isEqv
code: theorem eq_of_isEqv [DecidableEq α] (a b : Array α) : Array.isEqv a b (fun x y => x = y) → a = b 
goal: (a.isEqv b fun x y => decide (x = y)) = true → a = b

full_name: Array.isEqvAux_self
code: theorem isEqvAux_self [DecidableEq α] (a : Array α) (i : Nat) : Array.isEqvAux a a rfl (fun x y => x = y) i = true 
goal: a.isEqvAux a ⋯ (fun x y => decide (x = y)) i = true

full_name: Array.isEqv_self
code: theorem isEqv_self [DecidableEq α] (a : Array α) : Array.isEqv a a (fun x y => x = y) = true 
goal: (a.isEqv a fun x y => decide (x = y)) = true

full_name: Array.«instDecidableEq_.lake»
code: instance [DecidableEq α] : DecidableEq (Array α) 
goal: DecidableEq (Array α)
File: .lake/packages/lean4/src/lean/Init/Data/Array/QSort.lean

full_name: Array.qpartition.loop
code: def qpartition (as : Array α) (lt : α → α → Bool) (lo hi : Nat) : Nat × Array α 
goal: Nat × Array α

full_name: Array.qpartition
code: def qpartition (as : Array α) (lt : α → α → Bool) (lo hi : Nat) : Nat × Array α 
goal: Nat × Array α

full_name: Array.qsort.sort
code: @[inline] partial def qsort (as : Array α) (lt : α → α → Bool) (low := 0) (high := as.size - 1) : Array α 
goal: Array α

full_name: Array.qsort
code: @[inline] partial def qsort (as : Array α) (lt : α → α → Bool) (low := 0) (high := as.size - 1) : Array α 
goal: Array α
File: .lake/packages/lean4/src/lean/Init/Data/Array/BasicAux.lean

full_name: Array.of_push_eq_push
code: theorem Array.of_push_eq_push {as bs : Array α} (h : as.push a = bs.push b) : as = bs ∧ a = b 
goal: as = bs ∧ a = b

full_name: _private.«.lake».packages.lean4.src.lean.Init.Data.Array.BasicAux.0.List.size_toArrayAux
code: private theorem List.size_toArrayAux (as : List α) (bs : Array α) : (as.toArrayAux bs).size = as.length + bs.size 
goal: (as.toArrayAux bs).size = as.length + bs.size

full_name: _private.«.lake».packages.lean4.src.lean.Init.Data.Array.BasicAux.0.List.of_toArrayAux_eq_toArrayAux
code: private theorem List.of_toArrayAux_eq_toArrayAux {as bs : List α} {cs ds : Array α} (h : as.toArrayAux cs = bs.toArrayAux ds) (hlen : cs.size = ds.size) : as = bs ∧ cs = ds 
goal: as = bs ∧ cs = ds

full_name: List.toArray_eq_toArray_eq
code: @[simp] theorem List.toArray_eq_toArray_eq (as bs : List α) : (as.toArray = bs.toArray) = (as = bs) 
goal: (List.toArray as = List.toArray bs) = (as = bs)

full_name: Array.mapM'
code: def Array.mapM' [Monad m] (f : α → m β) (as : Array α) : m { bs : Array β // bs.size = as.size } 
goal: m { bs // bs.size = as.size }

full_name: Array.mapM'.go
code: def Array.mapM' [Monad m] (f : α → m β) (as : Array α) : m { bs : Array β // bs.size = as.size } 
goal: m { bs // bs.size = as.size }

full_name: _private.«.lake».packages.lean4.src.lean.Init.Data.Array.BasicAux.0.mapMonoMImp.go
code: @[inline] private unsafe def mapMonoMImp [Monad m] (as : Array α) (f : α → m α) : m (Array α) 
goal: m (Array α)

full_name: _private.«.lake».packages.lean4.src.lean.Init.Data.Array.BasicAux.0.mapMonoMImp
code: @[inline] private unsafe def mapMonoMImp [Monad m] (as : Array α) (f : α → m α) : m (Array α) 
goal: m (Array α)

full_name: Array.mapMonoM
code: /--
Monomorphic `Array.mapM`. The internal implementation uses pointer equality, and does not allocate a new array
if the result of each `f a` is a pointer equal value `a`.
-/
@[implemented_by mapMonoMImp] def Array.mapMonoM [Monad m] (as : Array α) (f : α → m α) : m (Array α) 
goal: m (Array α)

full_name: Array.mapMono
code: @[inline] def Array.mapMono (as : Array α) (f : α → α) : Array α 
goal: Array α
File: .lake/packages/lean4/src/lean/Init/Data/Array/BinSearch.lean

full_name: Array.binSearchAux
code: @[specialize] partial def binSearchAux {α : Type u} {β : Type v} [Inhabited β] (lt : α → α → Bool) (found : Option α → β) (as : Array α) (k : α) : Nat → Nat → β
  
goal: Nat → Nat → β

full_name: Array.binSearch
code: @[inline] def binSearch {α : Type} (as : Array α) (k : α) (lt : α → α → Bool) (lo := 0) (hi := as.size - 1) : Option α 
goal: Option α

full_name: Array.binSearchContains
code: @[inline] def binSearchContains {α : Type} (as : Array α) (k : α) (lt : α → α → Bool) (lo := 0) (hi := as.size - 1) : Bool 
goal: Bool

full_name: _private.«.lake».packages.lean4.src.lean.Init.Data.Array.BinSearch.0.Array.binInsertAux
code: @[specialize] private partial def binInsertAux {α : Type u} {m : Type u → Type v} [Monad m]
    (lt : α → α → Bool)
    (merge : α → m α)
    (add : Unit → m α)
    (as : Array α)
    (k : α) : Nat → Nat → m (Array α)
  
goal: Nat → Nat → m (Array α)

full_name: Array.binInsertM
code: @[specialize] def binInsertM {α : Type u} {m : Type u → Type v} [Monad m]
    (lt : α → α → Bool)
    (merge : α → m α)
    (add : Unit → m α)
    (as : Array α)
    (k : α) : m (Array α) 
goal: m (Array α)

full_name: Array.binInsert
code: @[inline] def binInsert {α : Type u} (lt : α → α → Bool) (as : Array α) (k : α) : Array α 
goal: Array α
File: .lake/packages/lean4/src/lean/Init/Data/Array/InsertionSort.lean

full_name: Array.insertionSort.traverse
code: @[inline] def Array.insertionSort (a : Array α) (lt : α → α → Bool) : Array α 
goal: Array α

full_name: Array.insertionSort.swapLoop
code: @[inline] def Array.insertionSort (a : Array α) (lt : α → α → Bool) : Array α 
goal: Array α

full_name: Array.insertionSort
code: @[inline] def Array.insertionSort (a : Array α) (lt : α → α → Bool) : Array α 
goal: Array α
File: .lake/packages/lean4/src/lean/Init/Data/Char/Lemmas.lean

full_name: Char.le_def
code: theorem le_def {a b : Char} : a ≤ b ↔ a.1 ≤ b.1 
goal: a ≤ b ↔ a.val ≤ b.val

full_name: Char.lt_def
code: theorem lt_def {a b : Char} : a < b ↔ a.1 < b.1 
goal: a < b ↔ a.val < b.val

full_name: Char.lt_iff_val_lt_val
code: theorem lt_iff_val_lt_val {a b : Char} : a < b ↔ a.val < b.val 
goal: a < b ↔ a.val < b.val

full_name: Char.not_le
code: @[simp] protected theorem not_le {a b : Char} : ¬ a ≤ b ↔ b < a 
goal: ¬a ≤ b ↔ b < a

full_name: Char.not_lt
code: @[simp] protected theorem not_lt {a b : Char} : ¬ a < b ↔ b ≤ a 
goal: ¬a < b ↔ b ≤ a

full_name: Char.le_refl
code: @[simp] protected theorem le_refl (a : Char) : a ≤ a 
goal: a ≤ a

full_name: Char.lt_irrefl
code: @[simp] protected theorem lt_irrefl (a : Char) : ¬ a < a 
goal: ¬a < a

full_name: Char.le_trans
code: protected theorem le_trans {a b c : Char} : a ≤ b → b ≤ c → a ≤ c 
goal: a ≤ b → b ≤ c → a ≤ c

full_name: Char.lt_trans
code: protected theorem lt_trans {a b c : Char} : a < b → b < c → a < c 
goal: a < b → b < c → a < c

full_name: Char.le_total
code: protected theorem le_total (a b : Char) : a ≤ b ∨ b ≤ a 
goal: a ≤ b ∨ b ≤ a

full_name: Char.lt_asymm
code: protected theorem lt_asymm {a b : Char} (h : a < b) : ¬ b < a 
goal: ¬b < a

full_name: Char.ne_of_lt
code: protected theorem ne_of_lt {a b : Char} (h : a < b) : a ≠ b 
goal: a ≠ b

full_name: Char.utf8Size_eq
code: theorem utf8Size_eq (c : Char) : c.utf8Size = 1 ∨ c.utf8Size = 2 ∨ c.utf8Size = 3 ∨ c.utf8Size = 4 
goal: c.utf8Size = 1 ∨ c.utf8Size = 2 ∨ c.utf8Size = 3 ∨ c.utf8Size = 4

full_name: Char.ofNat_toNat
code: @[simp] theorem ofNat_toNat (c : Char) : Char.ofNat c.toNat = c 
goal: Char.ofNat c.toNat = c

full_name: Char.Char.ext
code: @[ext] theorem Char.ext : {a b : Char} → a.val = b.val → a = b
  
goal: a.val = b.val → a = b

full_name: Char.Char.ext_iff
code: theorem Char.ext_iff {x y : Char} : x = y ↔ x.val = y.val 
goal: x = y ↔ x.val = y.val

full_name: String.csize
code: @[deprecated Char.utf8Size (since := "2024-06-04")] abbrev String.csize 
goal: Nat
File: .lake/packages/lean4/src/lean/Init/Data/Array/Subarray/Split.lean

full_name: Subarray.split
code: /--
Splits a subarray into two parts.
-/
def split (s : Subarray α) (i : Fin s.size.succ) : (Subarray α × Subarray α) 
goal: Subarray α × Subarray α

full_name: Subarray.drop
code: /--
Removes the first `i` elements of the subarray. If there are `i` or fewer elements, the resulting
subarray is empty.
-/
def drop (arr : Subarray α) (i : Nat) : Subarray α 
goal: Subarray α

full_name: Subarray.take
code: /--
Keeps only the first `i` elements of the subarray. If there are `i` or fewer elements, the resulting
subarray is empty.
-/
def take (arr : Subarray α) (i : Nat) : Subarray α 
goal: Subarray α
File: .lake/packages/lean4/src/lean/Init/Data/String/Lemmas.lean

full_name: String.data_eq_of_eq
code: protected theorem data_eq_of_eq {a b : String} (h : a = b) : a.data = b.data 
goal: a.data = b.data

full_name: String.ne_of_data_ne
code: protected theorem ne_of_data_ne {a b : String} (h : a.data ≠ b.data) : a ≠ b 
goal: a ≠ b

full_name: String.lt_irrefl
code: @[simp] protected theorem lt_irrefl (s : String) : ¬ s < s 
goal: ¬s < s

full_name: String.ne_of_lt
code: protected theorem ne_of_lt {a b : String} (h : a < b) : a ≠ b 
goal: a ≠ b
File: .lake/packages/lean4/src/lean/Init/Data/Queue.lean

full_name: Std.Queue
code: /--
A functional queue data structure, using two back-to-back lists.
If we think of the queue as having elements pushed on the front and
popped from the back, then the queue itself is effectively `eList ++ dList.reverse`.
-/
structure Queue (α : Type u) where
  /-- The enqueue list, which stores elements that have just been pushed
  (with the most recently enqueued elements at the head). -/
  eList : List α := []
  /-- The dequeue list, which buffers elements ready to be dequeued
  (with the head being the next item to be yielded by `dequeue?`). -/
  dList : List α := []
goal: Type u

full_name: Std.Queue.eList
code: /--
A functional queue data structure, using two back-to-back lists.
If we think of the queue as having elements pushed on the front and
popped from the back, then the queue itself is effectively `eList ++ dList.reverse`.
-/
structure Queue (α : Type u) where
  /-- The enqueue list, which stores elements that have just been pushed
  (with the most recently enqueued elements at the head). -/
  eList : List α := []
  /-- The dequeue list, which buffers elements ready to be dequeued
  (with the head being the next item to be yielded by `dequeue?`). -/
  dList : List α := []
goal: List α

full_name: Std.Queue.dList
code: /--
A functional queue data structure, using two back-to-back lists.
If we think of the queue as having elements pushed on the front and
popped from the back, then the queue itself is effectively `eList ++ dList.reverse`.
-/
structure Queue (α : Type u) where
  /-- The enqueue list, which stores elements that have just been pushed
  (with the most recently enqueued elements at the head). -/
  eList : List α := []
  /-- The dequeue list, which buffers elements ready to be dequeued
  (with the head being the next item to be yielded by `dequeue?`). -/
  dList : List α := []
goal: List α

full_name: Std.Queue.empty
code: /-- `O(1)`. The empty queue. -/
def empty : Queue α 
goal: Std.Queue α

full_name: Std.Queue.instEmptyCollection
code: instance : EmptyCollection (Queue α) 
goal: EmptyCollection (Std.Queue α)

full_name: Std.Queue.instInhabited
code: instance : Inhabited (Queue α) 
goal: Inhabited (Std.Queue α)

full_name: Std.Queue.isEmpty
code: /-- `O(1)`. Is the queue empty? -/
def isEmpty (q : Queue α) : Bool 
goal: Bool

full_name: Std.Queue.enqueue
code: /-- `O(1)`. Push an element on the front of the queue. -/
def enqueue (v : α) (q : Queue α) : Queue α 
goal: Std.Queue α

full_name: Std.Queue.enqueueAll
code: /-- `O(|vs|)`. Push a list of elements `vs` on the front of the queue. -/
def enqueueAll (vs : List α) (q : Queue α) : Queue α 
goal: Std.Queue α

full_name: Std.Queue.dequeue?
code: /--
`O(1)` amortized, `O(n)` worst case. Pop an element from the back of the queue,
returning the element and the new queue.
-/
def dequeue? (q : Queue α) : Option (α × Queue α) 
goal: Option (α × Std.Queue α)

full_name: Std.Queue.toArray
code: def toArray (q : Queue α) : Array α 
goal: Array α