Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Googleで答えが見つかりませんでした。
CでPHPdate('YmdHis')出力に相当するものはありますか:
date('YmdHis')
20130613153516
ありがとうございました!
完全な最小限の例を次に示します。
#include <stdio.h> #include <time.h> #define MAX 1024 int main(int argc, char ** argv) { char buffer[MAX]; time_t t; t = time(NULL); strftime(buffer, MAX, "%Y%m%d%I%M%S", localtime(&t)); printf("%s\n", buffer); return 0; }