gpt4 book ai didi

html - 我应该使用 ² 还是 2

转载 作者:行者123 更新时间:2023-12-03 16:17:07 27 4
gpt4 key购买 nike

考虑到基于机器的可读性(但不是唯一的,请在相关时提出建议),使用

square²

或者

square<sup>2</sup>

在我的 HTML 文件中(使用 utf-8 编码)?

最佳答案

我建议使用 <sup> html 上下文中的标记。

完整的官方答案可以在这里找到:Superscripts and Subscripts

第一个原因:

When used in mathematical context (MathML) it is recommended to consistently use style markup for superscripts and subscripts. This is because mathematical layout allows not just individual symbols, but entire expressions to be superscripted or subscripted in a regular, nested manner.



第二个原因:

However, when super and sub-scripts are to reflect semantic distinctions, it is easier to work with these meanings encoded in text rather than markup, for example, in phonetic or phonemic transcription. Otherwise, they would require markup in the middle of words, and they may also be inadvertently changed to normal style text, when exporting to plain text. This applies to the majority of super and subscripted characters in Unicode. On the other hand, some user agent may support certain superscripted or subscripted characters only when used as marked up text for example, because of lack of font support for them.

关于html - 我应该使用 ² 还是 <sup>2</sup>,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24519906/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com