Differences From Artifact [0c39de34a5]:
- File 残局文料/lua_lib/算机_程语_月_基类_数_位算.lua — part of check-in [77f6e5c564] at 2024-02-08 12:35:22 on branch trunk — 慢慢来 (user: 顽雨沉风, size: 253) [annotate] [blame] [check-ins using]
To Artifact [993ea5775b]:
- File 残局文料/lua_lib/算机_程语_月_基类_数_位算.lua — part of check-in [5b9fb5e09f] at 2024-02-13 05:00:42 on branch trunk — 好 (user: 顽雨沉风, size: 253) [annotate] [blame] [check-ins using]
1 | local bit = bit | | | | | | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | local bit = bit local s = {} -- 和与或 --~ 左数 --~ 右数 function s.位和(o1, o2) return bit.band(o1, o2) end -- 左移与右移 --~ 数 --~ 右移几位 function s.位右移(o1, o2) return bit.rshift(o1, o2) end return s |