Artifact 24685689a3aa54f69095a7302e98e6971c323e24f11069640f2ae17a0ceea53a:
- File single_doc/lua_lib/算机_程语_月_基类_数_位算.lua — part of check-in [60c256f91b] at 2024-06-27 23:36:58 on branch trunk — 0 (user: 顽雨沉风, size: 253) [annotate] [blame] [check-ins using]
- File 残局文料/lua_lib/算机_程语_月_基类_数_位算.lua — part of check-in [a4c0b3bd26] at 2024-02-13 05:09:26 on branch trunk — 好 (user: 顽雨沉风, size: 253) [annotate] [blame] [check-ins using]
local bit = bit local s = {} -- 和与或 --~ 左数 --~ 右数 function s.位和(u1, u2) return bit.band(u1, u2) end -- 左移与右移 --~ 数 --~ 右移几位 function s.位右移(u1, u2) return bit.rshift(u1, u2) end return s