<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>sasaplus1</author_name>
  <author_url>https://blog.hatena.ne.jp/sasaplus1/</author_url>
  <blog_title>四角革命前夜</blog_title>
  <blog_url>https://sasaplus1.hatenadiary.com/</blog_url>
  <categories>
    <anon>sh</anon>
  </categories>
  <description>連番の何かを書いたファイルを出力する場合、シェルスクリプトを書いて実行したりするのですが（RubyとかPythonとかでやりたいけどすぐに書けるほどスキルがない……）数が多いとそれなりに時間がかかります。 それが気になっていたのですが、ループでファイルに出力する際にちょっと記述に気を付ければすこしだけ高速に出力できるみたいです。 環境：RHEL 5.5 64bit aaa.sh #!/bin/sh for i in `seq 1 10000` do printf &quot;%05d\n&quot; $i &gt;&gt; aaa.dat done bbb.sh #!/bin/sh for i in `seq 1 10000…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fsasaplus1.hatenadiary.com%2Fentry%2F20110728%2F1311816352&quot; title=&quot;シェルスクリプトで少し速くファイルに出力する - 四角革命前夜&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2011-07-28 10:25:52</published>
  <title>シェルスクリプトで少し速くファイルに出力する</title>
  <type>rich</type>
  <url>https://sasaplus1.hatenadiary.com/entry/20110728/1311816352</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
