<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Str on Namtok blog</title>
    <link>https://blog.namtok-it.com/tags/str/</link>
    <description>Recent content in Str on Namtok blog</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <copyright>© 2025 </copyright>
    <lastBuildDate>Mon, 01 Feb 2021 00:00:00 +0000</lastBuildDate><atom:link href="https://blog.namtok-it.com/tags/str/index.xml" rel="self" type="application/rss+xml" />
    
    <item>
      <title>【python】文字列とdatetime型を互いに変換する strftime|strptime</title>
      <link>https://blog.namtok-it.com/posts/python_jp_date_str/</link>
      <pubDate>Mon, 01 Feb 2021 00:00:00 +0000</pubDate>
      
      <guid>https://blog.namtok-it.com/posts/python_jp_date_str/</guid>
      <description>&lt;ol&gt;
&lt;li&gt;&lt;a href=&#34;#str_to_dt&#34;&gt;&amp;lsquo;yyyy-mm-dd&amp;rsquo; → datetime 型&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#strjp_to_dt&#34;&gt;&amp;rsquo;○ 年 ○ 月 ○ 日&amp;rsquo; → datetime 型&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#dt_to_str&#34;&gt;datetime 型 → &amp;lsquo;yyyy-mm-dd&amp;rsquo;&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;#dt_to_strjp&#34;&gt;datetime 型 → &amp;lsquo;○ 年 ○ 月 ○ 日&amp;rsquo;&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h3 class=&#34;relative group&#34;&gt;&amp;lsquo;yyyy-mm-dd&amp;rsquo; → datetime 型&lt;a name=&#34;str_to_dt&#34;&gt;&lt;/a&gt; 
    &lt;div id=&#34;yyyy-mm-dd--datetime-型&#34; class=&#34;anchor&#34;&gt;&lt;/div&gt;
    
    &lt;span
        class=&#34;absolute top-0 w-6 transition-opacity opacity-0 ltr:-left-6 rtl:-right-6 not-prose group-hover:opacity-100&#34;&gt;
        &lt;a class=&#34;group-hover:text-primary-300 dark:group-hover:text-neutral-700&#34;
            style=&#34;text-decoration-line: none !important;&#34; href=&#34;#yyyy-mm-dd--datetime-%e5%9e%8b&#34; aria-label=&#34;Anchor&#34;&gt;#&lt;/a&gt;
    &lt;/span&gt;        
    
&lt;/h3&gt;
&lt;p&gt;文字列を datetime 型に変換するには、strptime メソッドを使います。&lt;br&gt;
&lt;a href=&#34;https://docs.python.org/ja/3/library/datetime.html#datetime.datetime.strptime&#34; target=&#34;_blank&#34;&gt;&lt;/a&gt;&lt;/p&gt;</description>
      
    </item>
    
  </channel>
</rss>
