2023-10-19

iso8601 time string

#include <chrono>

int main() {
  // 현재 시간을 가져옵니다.
  auto now = std::chrono::system_clock::now();

  // ISO 8601 포맷으로 시간을 만듭니다.
  std::string iso8601Time = std::to_string(now);

  // 시간을 출력합니다.
  std::cout << iso8601Time << std::endl;

  return 0;
}

댓글 없음:

댓글 쓰기

How to Convert EUC-KR Source Code to UTF-8

How to Convert EUC-KR Source Code to UTF-8 I found old STM32 firmware code. The files were in EUC-KR encoding. This is an old Korean text f...