跳到正文
Hugo 中文文档 · 社区翻译
首页 入门 内容管理 命令 Hugo 官网

文档目录

技能包
动态
方法
函数
cast
collections
compare
crypto
css
debug
diagrams
encoding
fmt
global
go template
hash
hugo
images
inflect
js
lang
math
  • math.Abs
  • math.Acos
  • math.Add
  • math.Asin
  • math.Atan
  • math.Atan2
  • math.Ceil
  • math.Cos
  • math.Counter
  • math.Div
  • math.Floor
  • math.Log
  • math.Max
  • math.MaxInt64
  • math.Min
  • math.Mod
  • math.ModBool
  • math.Mul
  • math.Pi
  • math.Pow
  • math.Product
  • math.Rand
  • math.Round
  • math.Sin
  • math.Sqrt
  • math.Sub
  • math.Sum
  • math.Tan
  • math.ToDegrees
  • math.ToRadians
openapi3
os
partials
path
reflect
resources
safe
strings
templates
time
transform
urls
入门
内容管理
命令
托管与部署
Hugo Pipes
Hugo 模块
模板
渲染钩子
短代码
配置
安装
故障排查
关于
速查
工具
参与贡献

math

math.Mod

返回两个整数的模。

签名
math.Mod VALUE1 VALUE2
返回类型
int64
别名
mod
{{ mod 15 3 }} → 0

英文原文:https://gohugo.io/functions/math/mod/

发布于 2026年10月2日(今天)·最后更新 2026年10月2日(今天)·提交 912b1d3

← 上一篇:math.Min 下一篇:math.ModBool →

本页目录

本站是社区维护的非官方中文翻译,内容译自 Hugo 官方文档;仅供学习参考,如有歧义,一切以官方英文原文为准。

站点:https://hugozh.cn/

遇到问题?到 Hugo 官方论坛 · 中文分类提问(中文区,提问前请先读 求助指南)

原文仓库:gohugoio/hugoDocs · 由 Hugo 0.147.5 构建 · 构建于 2026年10月2日(今天)

站点版本 v1.1.0 · 内容最近更新 2026年10月2日(今天) · 源码受版本控制(每次提交都会更新各页「最后更新」)

Hugo Hugo logos are copyright © Steve Francia 2013–2026. 本站为非官方社区项目,此处标识仅用于说明文档主题,不表示任何官方关联或背书。