0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

マイクロ秒(μs)を変数名としてどう表すか

Posted at

マイクロ秒を変数名のsuffixにつけるときに命名に迷ったのでメモ。
結論としては、_usでいいかなと。

microsecondsなので略すとmsでミリ秒と被ってしまう。
μsはギリシャ文字なのでASCII文字で表したいため使えない。

候補
_ms
_micros
_micro_seconds
_mus
_us

  • _ms
    ミリ秒と被るのでなし
  • _micros
  • _micro_seconds
    状況に置いては採用もあり。ただsuffixにこんなに文字数は使いたくないので基本なし。
  • _mus
    μを"mew" (/mju/)と発音するため。普通にあり。
  • _us
    μとuは別ものなので怒られそうな気もするけど、システムコールでもusleepとか使ってるしこれでいいかも。

reference
なんか議論してるやつ、参考にはしてない
https://forum.wordreference.com/threads/ms-milliseconds-and-microseconds.289143/

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?